|
JXTA | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.jxta.impl.xindice.core.data.Value
public class Value
Value is the primary base class for all data storing objects. The content window of Value objects are immutable, but the underlying byte array is not.
Field Summary | |
---|---|
protected byte[] |
data
|
protected int |
len
|
protected int |
pos
|
Constructor Summary | |
---|---|
Value(byte[] data)
|
|
Value(byte[] data,
int pos,
int len)
|
|
Value(String data)
|
|
Value(Value value)
|
Method Summary | |
---|---|
int |
compareTo(Object obj)
|
int |
compareTo(Value value)
|
boolean |
contains(Value value)
|
void |
copyTo(byte[] tdata,
int tpos)
|
void |
copyTo(byte[] tdata,
int tpos,
int len)
|
boolean |
endsWith(Value value)
|
boolean |
equals(Object obj)
|
boolean |
equals(Value value)
|
byte[] |
getData()
getData retrieves the data being stored by the Value as a byte array. |
InputStream |
getInputStream()
getInputStream returns an InputStream for the Value. |
int |
getLength()
getLength retrieves the length of the data being stored by the Value. |
int |
hashCode()
|
boolean |
startsWith(Value value)
|
void |
streamTo(OutputStream out)
streamTo streams the content of the Value to an OutputStream. |
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected byte[] data
protected int pos
protected int len
Constructor Detail |
---|
public Value(Value value)
public Value(byte[] data)
public Value(byte[] data, int pos, int len)
public Value(String data)
Method Detail |
---|
public final byte[] getData()
public final int getLength()
public final InputStream getInputStream()
public final void streamTo(OutputStream out) throws IOException
out
- the OutputStream
IOException
- if an io error occurspublic final void copyTo(byte[] tdata, int tpos)
public final void copyTo(byte[] tdata, int tpos, int len)
public final String toString()
toString
in class Object
public int hashCode()
hashCode
in class Object
public boolean equals(Value value)
public boolean equals(Object obj)
equals
in class Object
public final int compareTo(Value value)
public final int compareTo(Object obj)
compareTo
in interface Comparable
public final boolean startsWith(Value value)
public final boolean endsWith(Value value)
public final boolean contains(Value value)
|
JXSE | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |