public interface PropertyArrayInt
PropertyAtomInt
.Modifier and Type | Method and Description |
---|---|
int |
add(int value)
Creates a
PropertyAtomInt with the given int
and appends it to the array. |
void |
add(int index,
int value)
Creates a
PropertyAtomInt with the given int
and inserts it into the array at the specified position. |
PropertyAtomInt |
removePropertyAtom(int value)
Removes the first
PropertyAtomInt with the given value
that is found in this array. |
void |
set(int index,
int value)
Sets the
PropertyAtomInt at the given index to the given int . |
int add(int value)
PropertyAtomInt
with the given int
and appends it to the array.value
- the int
to add.void add(int index, int value)
PropertyAtomInt
with the given int
and inserts it into the array at the specified position.
This method shifts the PropertyAtomInt
currently at
that position (if any) and any subsequent PropertyAtomInt
to the right
(i.e. adds one to their indices).index
- the position at which to insert.value
- the int
to add.java.lang.IndexOutOfBoundsException
- - if the index is less than zero or more than the size of the array.PropertyAtomInt removePropertyAtom(int value)
PropertyAtomInt
with the given value
that is found in this array.
This method shifts all the subsequent array elements to the left
(i.e. substracts one to their indices).
It returns null if no matching value is found.value
- the int
to search for in the array.PropertyAtomInt
, or null if none matched.void set(int index, int value)
PropertyAtomInt
at the given index to the given int
.
If index == length
, this method will call add(index, value)
instead.index
- the index at which the value is to be set.value
- the int
to set at the index.java.lang.IndexOutOfBoundsException
- - if the index is less than zero or more than the current size of the array.