|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjodd.util.buffer.FastLongBuffer
public class FastLongBuffer
Fast, fast long buffer.
| Constructor Summary | |
|---|---|
FastLongBuffer()
Creates a new long buffer. |
|
FastLongBuffer(int size)
Creates a new long buffer, with a buffer capacity of
the specified size, in bytes. |
|
| Method Summary | |
|---|---|
FastLongBuffer |
append(FastLongBuffer buff)
Appends another fast buffer to this one. |
FastLongBuffer |
append(long element)
Appends single long to buffer. |
FastLongBuffer |
append(long[] array)
Appends long array to buffer. |
FastLongBuffer |
append(long[] array,
int off,
int len)
Appends long array to buffer. |
long[] |
array(int index)
Returns long inner array chunk at given index. |
void |
clear()
Resets the buffer content. |
long |
get(int index)
Returns long element at given index. |
int |
index()
Returns current index of inner long array chunk. |
boolean |
isEmpty()
Tests if this buffer has no elements. |
int |
offset()
Returns the offset of last used element in current inner array chunk. |
int |
size()
Returns buffer size. |
long[] |
toArray()
Creates long array from buffered content. |
long[] |
toArray(int start,
int len)
Creates long subarray from buffered content. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FastLongBuffer()
long buffer. The buffer capacity is
initially 1024 bytes, though its size increases if necessary.
public FastLongBuffer(int size)
long buffer, with a buffer capacity of
the specified size, in bytes.
size - the initial size.
java.lang.IllegalArgumentException - if size is negative.| Method Detail |
|---|
public FastLongBuffer append(long[] array,
int off,
int len)
long array to buffer.
public FastLongBuffer append(long[] array)
long array to buffer.
public FastLongBuffer append(long element)
long to buffer.
public FastLongBuffer append(FastLongBuffer buff)
public int size()
public boolean isEmpty()
public int index()
long array chunk.
Represents the index of last used inner array chunk.
public int offset()
public long[] array(int index)
long inner array chunk at given index.
May be used for iterating inner chunks in fast manner.
public void clear()
public long[] toArray()
long array from buffered content.
public long[] toArray(int start,
int len)
long subarray from buffered content.
public long get(int index)
long element at given index.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||