Input<T>, java.io.Closeable, java.lang.AutoCloseableCircularArrayInputpublic class ArrayInput<T> extends java.lang.Object implements Input<T>
| Modifier and Type | Field | Description |
|---|---|---|
protected int |
i |
|
protected T[] |
items |
|
protected int |
size |
| Constructor | Description |
|---|---|
ArrayInput(T[] items) |
| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
Does nothing
|
T |
get() |
Get next item
|
int |
get(java.util.List<T> buffer,
int maxCount) |
Bulk get into the specified buffer
|
void |
reset() |
Reset this input making this readable from the beginning
|
long |
skip(long itemsCount) |
Skip some items.
|
java.lang.String |
toString() |
protected final T[] items
protected int size
protected int i
public ArrayInput(T[] items)
public T get() throws java.io.EOFException, java.io.IOException
Inputpublic int get(java.util.List<T> buffer, int maxCount) throws java.io.EOFException, java.io.IOException
public long skip(long itemsCount)
throws java.io.IOException
Inputpublic void reset()
throws java.io.IOException
Inputpublic void close()
throws java.io.IOException
close in interface java.lang.AutoCloseableclose in interface java.io.Closeablejava.io.IOException - doesn't throwpublic java.lang.String toString()
toString in class java.lang.Object