|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface DataStructure
Defines the class as a standard object with particular bit representation, exposing methods to read and write that representation.
Method Summary | |
---|---|
Hash |
calculateHash()
Calculate the SHA256 value of this object (useful for a few scenarios) |
void |
fromBase64(java.lang.String data)
Load the structure from the base 64 encoded data provided |
void |
fromByteArray(byte[] data)
|
void |
readBytes(java.io.InputStream in)
Load up the current object with data from the given stream. |
java.lang.String |
toBase64()
render the structure into modified base 64 notation |
byte[] |
toByteArray()
|
void |
writeBytes(java.io.OutputStream out)
Write out the data structure to the stream, using the format defined in the I2P data structure specification. |
Method Detail |
---|
void readBytes(java.io.InputStream in) throws DataFormatException, java.io.IOException
in
- stream to read from
DataFormatException
- if the data is improperly formatted
java.io.IOException
- if there was a problem reading the streamvoid writeBytes(java.io.OutputStream out) throws DataFormatException, java.io.IOException
out
- stream to write to
DataFormatException
- if the data was incomplete or not yet ready to be written
java.io.IOException
- if there was a problem writing to the streamjava.lang.String toBase64()
void fromBase64(java.lang.String data) throws DataFormatException
DataFormatException
byte[] toByteArray()
void fromByteArray(byte[] data) throws DataFormatException
DataFormatException
Hash calculateHash()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |