|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.bigdata.btree.raba.EmptyRaba
public abstract class EmptyRaba
An immutable, empty IRaba.
| Nested Class Summary | |
|---|---|
static class |
EmptyRaba.EmptyKeysRaba
An empty, immutable B+Tree keys IRaba. |
static class |
EmptyRaba.EmptyValuesRaba
An empty, immutable B+Tree values IRaba. |
| Field Summary | |
|---|---|
static IRaba |
KEYS
An empty, immutable B+Tree keys IRaba instance. |
static IRaba |
VALUES
An empty, immutable B+Tree values IRaba instance. |
| Constructor Summary | |
|---|---|
EmptyRaba()
De-serialization ctor. |
|
| Method Summary | |
|---|---|
int |
add(byte[] a)
Append a byte[] value to the end of the logical byte[][] (optional operation). |
int |
add(byte[] value,
int off,
int len)
Append a byte[] value to the end of the logical byte[][] (optional operation). |
int |
add(DataInput in,
int len)
Append a byte[] value to the end of the logical byte[][] (optional operation). |
int |
capacity()
The capacity of the logical byte[][]. |
int |
copy(int index,
OutputStream os)
Copy the value at the specified index onto the output stream. |
byte[] |
get(int index)
Return the byte[] at the specified index. |
boolean |
isEmpty()
True iff the logical byte[][] is empty. |
boolean |
isFull()
True iff the logical byte[][] is full. |
boolean |
isNull(int index)
Return true iff the byte[] at that index is
null. |
boolean |
isReadOnly()
Return true if this implementation is read-only. |
Iterator<byte[]> |
iterator()
Iterator visits the byte[] elements in the view order. |
int |
length(int index)
The length of the byte[] at that index. |
void |
readExternal(ObjectInput in)
|
int |
search(byte[] searchKey)
Search for the given searchKey in the key buffer (optional operation). |
void |
set(int index,
byte[] a)
Set the byte[] value at the specified index (optional operation). |
int |
size()
The #of entries in the logical byte[][]. |
void |
writeExternal(ObjectOutput out)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.bigdata.btree.raba.IRaba |
|---|
isKeys |
| Field Detail |
|---|
public static transient IRaba KEYS
IRaba instance.
public static transient IRaba VALUES
IRaba instance.
| Constructor Detail |
|---|
public EmptyRaba()
| Method Detail |
|---|
public final int capacity()
IRaba
capacity in interface IRabapublic final boolean isEmpty()
IRaba
isEmpty in interface IRabapublic final boolean isFull()
IRaba
isFull in interface IRabapublic final int size()
IRaba
size in interface IRabapublic final boolean isReadOnly()
IRabatrue if this implementation is read-only.
isReadOnly in interface IRabapublic final boolean isNull(int index)
IRabatrue iff the byte[] at that index is
null. If IRaba.isKeys() would return
true then this method MUST return false since
nulls are not permitted for B+Tree keys.
isNull in interface IRabaindex - The index in [0:IRaba.size()-1].public final int length(int index)
IRaba
length in interface IRabaindex - The index in [0:IRaba.size()-1].
public final byte[] get(int index)
IRaba
get in interface IRabaindex - The index in [0:IRaba.size()-1].
null if a
null value was stored at that index.
public final int copy(int index,
OutputStream os)
IRabaByteArrayBuffer so that the same backing
byte[] can be overwritten by each visited key.
copy in interface IRabaindex - The index in [0:IRaba.size()-1].
public final Iterator<byte[]> iterator()
IRabanull, then the iterator will report a null for
that element.
iterator in interface IRabaiterator in interface Iterable<byte[]>public final int search(byte[] searchKey)
IRaba
entryIndex = -entryIndex - 1or just
entryIndex = -entryIndexif you are looking for the first key after the searchKey.
search in interface IRabasearchKey - The search key.
(-(insertion point) - 1). The insertion point is
defined as the point at which the key would be inserted. Note
that this guarantees that the return value will be >= 0 if and
only if the key is found.
public final void set(int index,
byte[] a)
IRaba
set in interface IRabaindex - The index in [0:IRaba.size()-1].a - The byte[] value.public final int add(byte[] a)
IRaba
add in interface IRabaa - A value.
public final int add(byte[] value,
int off,
int len)
IRaba
add in interface IRabavalue - A valueoff - The offset of the first byte to be copied.len - The #of bytes to be copied.
public final int add(DataInput in,
int len)
throws IOException
IRaba
add in interface IRabain - The input stream from which the byte[] will be read.len - The #of bytes to be read.
IOException
public void readExternal(ObjectInput in)
throws IOException,
ClassNotFoundException
readExternal in interface ExternalizableIOException
ClassNotFoundException
public void writeExternal(ObjectOutput out)
throws IOException
writeExternal in interface ExternalizableIOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||