public interface PropertyArray extends Property
PropertyAtom
).Property.PropertyBoolean, Property.PropertyConcept, Property.PropertyConceptReference, Property.PropertyContainedConcept, Property.PropertyDateTime, Property.PropertyDouble, Property.PropertyInt, Property.PropertyLong, Property.PropertyString
HISTORY_POLICY_ALL_VALUES, HISTORY_POLICY_CHANGES_ONLY
Modifier and Type | Method and Description |
---|---|
PropertyAtom |
add()
Creates a
PropertyAtom without setting a value and appends it to the end of the array. |
void |
add(int index,
java.lang.Object value)
Creates a
PropertyAtom with the given value, and inserts it at the specified position in the array. |
int |
add(java.lang.Object value)
Creates a
PropertyAtom with the given value, and appends it to the end of the array. |
void |
clear()
Removes all the elements from this list.
|
PropertyAtom |
get(int index)
Returns the
PropertyAtom at the specified position in the array. |
java.lang.String |
getString()
Gets a
String representation of the current value of this PropertyArray . |
int |
length()
Returns the length of this array.
|
PropertyAtom |
remove(int index)
Removes the
PropertyAtom at the specified position in this list. |
PropertyAtom[] |
toArray()
Returns an array containing all of the elements in this
PropertyArray in the correct order. |
PropertyAtom[] |
toArray(PropertyAtom[] array)
Returns an array containing all of the elements in this
PropertyArray in the correct order,
and whose runtime type is that of the specified array. |
getHistoryPolicy, getHistorySize, getName, getParent
int length()
void clear()
int add(java.lang.Object value)
PropertyAtom
with the given value, and appends it to the end of the array.
This method does not check for duplicates (i.e. existence of the same value in the array).value
- the object to create the new PropertyAtom
with.PropertyAtom
was inserted.void add(int index, java.lang.Object value)
PropertyAtom
with the given value, and inserts it at the specified position in the array.
Shifts the element currently at that position (if any) and any subsequent elements to the right
(i.e. adds one to their indices).index
- the index at which the specified element is to be inserted.value
- the value of the property atom to insert.java.lang.IndexOutOfBoundsException
- if the index is invalid.PropertyAtom remove(int index)
PropertyAtom
at the specified position in this list.
Shifts any subsequent elements to the left (i.e. subtracts one from their indices).index
- the index of the element to remove.java.lang.IndexOutOfBoundsException
- if index was invalid.PropertyAtom get(int index)
PropertyAtom
at the specified position in the array.index
- the index of the PropertyAtom
to return.java.lang.IndexOutOfBoundsException
- if the index is invalid.PropertyAtom[] toArray()
PropertyArray
in the correct order.PropertyArray
in the correct order.java.lang.String getString()
String
representation of the current value of this PropertyArray
.PropertyAtom[] toArray(PropertyAtom[] array)
PropertyArray
in the correct order,
and whose runtime type is that of the specified array.
If the result fits in the specified array, it is returned therein.
Otherwise, a new array is allocated with the runtime type of the specified array
and the size of this PropertyArray
.
If the list fits in the specified array with room to spare (i.e. if the array has more elements than the list), the element in the array immediately following the end of the collection are set to null. This is useful in determining the length of the list only if the caller knows that the list does not contain any null element.
array
- the array into which the elements of the list are to be stored, if it is big enough;
otherwise, a new array of the same runtime type will be allocated for this purpose.PropertyArray
.java.lang.ArrayStoreException
- - if the runtime type of a is not a supertype of the runtime
type of every element in this list.PropertyAtom add()
PropertyAtom
without setting a value and appends it to the end of the array.PropertyAtom
element that was added.