|
CDMA plugin API
3.1.0
CDMA core library
|
The IAttribute interface describes a metadata of a IContainer. More...
Inherits IModelObject.
Public Member Functions | |
| String | getName () |
| Class<?> | getType () |
| boolean | isString () |
| boolean | isArray () |
| int | getLength () |
| IArray | getValue () |
| String | getStringValue () |
| String | getStringValue (int index) |
| Number | getNumericValue () |
| Number | getNumericValue (int index) |
| boolean | equals (Object o) |
| int | hashCode () |
| String | toString () |
| void | setStringValue (String val) |
| void | setValue (IArray value) |
The IAttribute interface describes a metadata of a IContainer.
pluginAPI CDMA attribute, with name and value. That metadata is carried by data items and groups. Those data have a name, an element type, size and can be whether an IArray or a scalar.
| boolean org.gumtree.data.interfaces.IAttribute.equals | ( | Object | o | ) |
Instances which have same content's values are equal.
| o | Object |
Get the number of element within the array of values.
Get the name of this IAttribute. Attribute's names are unique within a IContainer.
Retrieve numeric value. Equivalent to getNumericValue(0)
| Number org.gumtree.data.interfaces.IAttribute.getNumericValue | ( | int | index | ) |
Retrieve a numeric value by index. If its a String, it will try to parse it as a double.
| index | the index into the value array. |
value[index], or null if its a non-parsable String or the index is out of range. Retrieve the string value or null if the value isn't a string.
| String org.gumtree.data.interfaces.IAttribute.getStringValue | ( | int | index | ) |
Retrieve the string value or null if the value isn't a string.
| index | integer value |
| Class<?> org.gumtree.data.interfaces.IAttribute.getType | ( | ) |
Get the data type of the IAttribute value.
Override Object.hashCode() to implement equals.
| boolean org.gumtree.data.interfaces.IAttribute.isArray | ( | ) |
True if the value is an array (getLength() > 1).
| boolean org.gumtree.data.interfaces.IAttribute.isString | ( | ) |
True if value is a string or an array of strings.
| void org.gumtree.data.interfaces.IAttribute.setStringValue | ( | String | val | ) |
Set the value as a String, trimming trailing zeroes.
| val | String object |
| void org.gumtree.data.interfaces.IAttribute.setValue | ( | IArray | value | ) |
String representation.