Type for storing a group of key-value pairs that can be attached to entities
pw:: | Type for storing a group of key-value pairs that can be attached to entities |
Static Actions | |
create | This action creates a new attribute dictionary object. |
getAll | This action gets a list of all of the current attribute dictionaries. |
getByName | This action gets an attribute dictionary object with the given name. |
Instance Attributes | |
Name | This attribute is the name of the attribute dictionary. |
Class | This attribute is the class of the attribute dictionary. |
Instance Actions | |
getDictionary | This action gets a dictionary of key-value pairs of attributes that are defined by this attribute dictionary. |
setDictionary | This action assigns the given key-value pairs as the attributes for this attribute dictionary. |
updateDictionary | This action updates the key-value pairs for this attribute dictionary. |
renameDictionaryKey | This action renames a key of this attribute dictionary. |
getEntities | This action gets a list of entities that this dictionary has been attached to. |
delete | This action deletes this attribute dictionary. |
pw::AttributeDictionary create
This action creates a new attribute dictionary object.
This action has no parameters.
This action returns a new pw::AttributeDictionary object.
pw::AttributeDictionary getAll ?-class class_name?
This action gets a list of all of the current attribute dictionaries.
-class class_name | This optional flag limits this action to only return attribute dictionaries that have been assigned the given class name. The default behavior is to return all attribute dictionaries. |
This action returns a list of pw::AttributeDictionary objects.
pw::AttributeDictionary getByName name
This action gets an attribute dictionary object with the given name.
name | This parameter is the string name of the attribute dictionary to get. |
This action returns a pw::AttributeDictionary object.
$attr get/setName name
This attribute is the name of the attribute dictionary.
This attribute is a string.
The default for this attribute is a uniquely generated name.
$attr get/setClass class
This attribute is the class of the attribute dictionary.
This attribute is a string.
The default for this attribute is the string User.
$attr getDictionary ?-modified? ?attr_keys?
This action gets a dictionary of key-value pairs of attributes that are defined by this attribute dictionary.
-modified | This optional flag is the notification to include the modifed state of each key-value pair in the result. When included, the result will contain an additional list of boolean values that represent the modified state of each pair. |
attr_keys | This optional parameter is a string key or a list of string keys to limit the attributes which should be returned by this action. If not specified, all existing attributes will be returned by this action. |
This action returns a list of strings that can be converted into a tcl dictionary (list of alternating keys and values). If the -modified flag was used, a second list is returned with modified state for each key-value pair.
$attr setDictionary dict
This action assigns the given key-value pairs as the attributes for this attribute dictionary.
dict | This parameter is a list of string values of alternating key-value pairs. If the list is an empty list, all key-value pairs of the dictionary will be removed. |
This action returns nothing.
$attr updateDictionary ?-force? key ?value?
This action updates the key-value pairs for this attribute dictionary.
-force | This optional flag will cause the key-value pair to be added if it doesn’t already exist. The default behavior is to only update the dictionary is the key exists. |
key | This parameter is a string key to update. |
value | This optional parameter is a string value of a key-value pair to set for the dictionary. If this parameter is not given, the key will be removed from the dictionary if it exists. If an empty string is given, it will be assigned to the key. |
This action returns nothing.
$attr getEntities
This action gets a list of entities that this dictionary has been attached to.
This action has no parameters.
This action returns a list of pw::Entity objects.
This action creates a new attribute dictionary object.
pw::AttributeDictionary create
This action gets a list of all of the current attribute dictionaries.
pw::AttributeDictionary getAll ?-class class_name?
This action gets an attribute dictionary object with the given name.
pw::AttributeDictionary getByName name
This attribute is the name of the attribute dictionary.
$attr get/setName name
This attribute is the class of the attribute dictionary.
$attr get/setClass class
This action gets a dictionary of key-value pairs of attributes that are defined by this attribute dictionary.
$attr getDictionary ?-modified? ?attr_keys?
This action assigns the given key-value pairs as the attributes for this attribute dictionary.
$attr setDictionary dict
This action updates the key-value pairs for this attribute dictionary.
$attr updateDictionary ?-force? key ?value?
This action renames a key of this attribute dictionary.
$attr renameDictionaryKey key new_key
This action gets a list of entities that this dictionary has been attached to.
$attr getEntities
This action deletes this attribute dictionary.
$attr delete