|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.sunflow.util.IntArray
public final class IntArray
| Constructor Summary | |
|---|---|
IntArray()
|
|
IntArray(int capacity)
|
|
| Method Summary | |
|---|---|
void |
add(int i)
Append an integer to the end of the array. |
int |
get(int index)
Read value from the array. |
int |
getSize()
Returns the number of elements added to the array. |
void |
set(int index,
int value)
Write a value to the specified index. |
int[] |
trim()
Return a copy of the array, trimmed to fit the size of its contents exactly. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IntArray()
public IntArray(int capacity)
| Method Detail |
|---|
public final void add(int i)
i -
public final void set(int index,
int value)
index - value - public final int get(int index)
index - index into the array
public final int getSize()
public final int[] trim()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||