public interface ProxyArray extends Proxy
Proxy
Modifier and Type | Method and Description |
---|---|
static ProxyArray |
fromArray(Object... values)
Creates a proxy array backed by a Java array.
|
static ProxyArray |
fromList(List<Object> values)
Creates a proxy array backed by a Java List.
|
Object |
get(long index)
Returns the element at the given index.
|
long |
getSize()
Returns the reported size of the array.
|
default boolean |
remove(long index)
Removes the element at the given index.
|
void |
set(long index,
Value value)
Sets the element at the given index.
|
Object get(long index)
ArrayIndexOutOfBoundsException
- if the index is out of boundsUnsupportedOperationException
- if the operation is not supportedvoid set(long index, Value value)
ArrayIndexOutOfBoundsException
- if the index is out of boundsUnsupportedOperationException
- if the operation is not supporteddefault boolean remove(long index)
true
when the element was removed, false
when the element
didn't exist.ArrayIndexOutOfBoundsException
- if the index is out of boundsUnsupportedOperationException
- if the operation is not supportedlong getSize()
static ProxyArray fromArray(Object... values)
unboxed
.static ProxyArray fromList(List<Object> values)
unboxed
.