![]() |
AppEasy Core SDK
1.5.0
Cross platform mobile and desktop app and game development SDK - The easy way to make apps
|
A user property list. More...
#include <CzUserProperty.h>
Public Member Functions | |
| CzUserPropertyList () | |
| ~CzUserPropertyList () | |
| bool | addProperty (CzXomlNamedProperty *prop) |
| Adds a property to a property list. | |
| void | removeProperty (CzXomlNamedProperty *prop, bool destroy=true) |
| Removes the property described by prop from the property list. | |
| void | clearProperties (bool destroy=true) |
| Clears the properties. | |
| CzXomlNamedProperty * | findProperty (unsigned int name_hash) |
| Searches the properties list for the named property. | |
| CzXomlNamedProperty * | findProperty (const char *name) |
| Searches the properties list for the named property. | |
| bool | setProperty (const char *name, const CzString &data, bool delta) |
| Sets the named property. | |
| bool | setProperty (unsigned int name_hash, const CzString &data, bool delta) |
| Sets the named property. | |
| bool | setPropertyToVariable (unsigned int name_hash, CzXomlVariable &var) |
| Copies the value of the property to a variable. | |
| int | LoadFromXoml (IzXomlResource *parent, bool load_children, CzXmlNode *node) |
| Creates an instance of this class from XOML. | |
Protected Attributes | |
| CzList< CzXomlNamedProperty * > | Properties |
A user property list.
Property lists can be added to scenes and actors to provide a mechanism for users to track and modify their own properties
| CzUserPropertyList::CzUserPropertyList | ( | ) | [inline] |
| CzUserPropertyList::~CzUserPropertyList | ( | ) | [inline] |
| bool CzUserPropertyList::addProperty | ( | CzXomlNamedProperty * | prop | ) |
Adds a property to a property list.
| [in] | prop | If non-null, the property. |
| void CzUserPropertyList::clearProperties | ( | bool | destroy = true | ) |
Clears the properties.
| destroy | true to destroy all properties. |
| CzXomlNamedProperty * CzUserPropertyList::findProperty | ( | unsigned int | name_hash | ) |
Searches the properties list for the named property.
| name_hash | The propery name as a string hash. |
| CzXomlNamedProperty * CzUserPropertyList::findProperty | ( | const char * | name | ) |
Searches the properties list for the named property.
| name | The property name. |
| int CzUserPropertyList::LoadFromXoml | ( | IzXomlResource * | parent, |
| bool | load_children, | ||
| CzXmlNode * | node | ||
| ) | [virtual] |
Creates an instance of this class from XOML.
LoadFromXoml is the main method used by all classes that can be instantiated from XOML mark-up. This method creates an instance of this class from the supplied XML node structure specified by node.
| [in] | parent | If non-null, the parent. |
| load_children | true to load child nodes. | |
| [in] | node | If non-null, the XOML markup node that defines this object |
Implements IzXomlResource.
| void CzUserPropertyList::removeProperty | ( | CzXomlNamedProperty * | prop, |
| bool | destroy = true |
||
| ) |
Removes the property described by prop from the property list.
| [in] | prop | If non-null, the property. |
| destroy | true to destroy property. |
| bool CzUserPropertyList::setProperty | ( | const char * | name, |
| const CzString & | data, | ||
| bool | delta | ||
| ) |
Sets the named property.
| name | The name of the property. |
| data | The data to assign to the property. |
| delta | true to add value nistead of set. |
| bool CzUserPropertyList::setProperty | ( | unsigned int | name_hash, |
| const CzString & | data, | ||
| bool | delta | ||
| ) |
Sets the named property.
| name_hash | The name of the property as a string hash. |
| data | The data to assign to the property. |
| delta | true to add value nistead of set. |
| bool CzUserPropertyList::setPropertyToVariable | ( | unsigned int | name_hash, |
| CzXomlVariable & | var | ||
| ) |
Copies the value of the property to a variable.
| name_hash | The property name as a string hash. | |
| [out] | var | The target variable. |
CzList<CzXomlNamedProperty*> CzUserPropertyList::Properties [protected] |