|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectorg.h2.dev.util.ImmutableArray3<K>
K - the typepublic abstract class ImmutableArray3<K>
An immutable array.
| Constructor Summary | |
|---|---|
ImmutableArray3()
|
|
| Method Summary | ||
|---|---|---|
K[] |
array()
Get the data. |
|
static
|
create(K... array)
Create an immutable array. |
|
static
|
empty()
Get an empty immutable array. |
|
abstract K |
get(int index)
Get the entry at this index. |
|
abstract ImmutableArray3<K> |
insert(int index,
K obj)
Insert an entry at this index. |
|
java.util.Iterator<K> |
iterator()
Get an iterator over all entries. |
|
abstract int |
length()
Get the length. |
|
abstract ImmutableArray3<K> |
remove(int index)
Remove the entry at this index. |
|
abstract ImmutableArray3<K> |
set(int index,
K obj)
Set the entry at this index. |
|
ImmutableArray3<K> |
subArray(int fromIndex,
int toIndex)
Get a sub-array. |
|
java.lang.String |
toString()
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ImmutableArray3()
| Method Detail |
|---|
public abstract int length()
public abstract K get(int index)
index - the index
public abstract ImmutableArray3<K> set(int index,
K obj)
index - the indexobj - the object
public abstract ImmutableArray3<K> insert(int index,
K obj)
index - the indexobj - the object
public abstract ImmutableArray3<K> remove(int index)
index - the index
public ImmutableArray3<K> subArray(int fromIndex,
int toIndex)
fromIndex - the index of the first entrytoIndex - the end index, plus one
public static <K> ImmutableArray3<K> create(K... array)
array - the data
public K[] array()
public java.lang.String toString()
toString in class java.lang.Objectpublic static <K> ImmutableArray3<K> empty()
K - the key type
public java.util.Iterator<K> iterator()
iterator in interface java.lang.Iterable<K>
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||