Returns all values of the specified attribute contained in the specified element.
For a single-component (simple) value, the function returns a single-element array containing that value.
For a multi-component (list) value (see GOMAttribute.multiValued
),
the property returns an array containing all value components (list items).
Parameters:
element
getAttrValues(contextElement, attrName)
attrName
Note: Some DSM Types may support pseudo- (or formula-) attributes. Such attributes are specified with the FlexQuery expressions which calculate the attributes' values from another (real) attributes, possible with the use of some functions.
Pseudo-attributes are treated the same way as the normal ones. (That's actually why the pseudo-attributes were introduced in the first place). Obtaining the value of a pseudo-attribute will just evoke the internal processing of its formula (therefore, if an error occurred during this, it will be reported accordingly). Externally, accessing pseudo-attributes looks the same as the accessing the normal ones. So does this function.
If the element contains no attribute with the specified name
(or in the case element == null
), an empty array is returned.
getAttrValue(), getAttrFullValue(), hasAttrValue(),
GOMAttribute.values, getValuesByLPath()
(1) You may call this function in a more method-like style:
element.getAttrValues(attrName)
element.getValuesByLPath("@attrName")