| java.lang.Object org.apache.poi.hpsf.ClassID
ClassID | public class ClassID (Code) | | Represents a class ID (16 bytes). Unlike other little-endian
type the
ClassID is not just 16 bytes stored in the wrong
order. Instead, it is a double word (4 bytes) followed by two
words (2 bytes each) followed by 8 bytes.
author: Rainer Klute author: href="mailto:klute@rainer-klute.de"><klute@rainer-klute.de> version: $Id: ClassID.java 489730 2006-12-22 19:18:16Z bayard $ since: 2002-02-09 |
Field Summary | |
final public static int | LENGTH | protected byte[] | bytes The bytes making out the class ID in correct order,
i.e. |
Constructor Summary | |
public | ClassID(byte[] src, int offset) | public | ClassID() |
Method Summary | |
public boolean | equals(Object o) | public byte[] | getBytes() Gets the bytes making out the class ID. | public int | hashCode() | public int | length() | public byte[] | read(byte[] src, int offset) | public void | setBytes(byte[] bytes) Sets the bytes making out the class ID.
Parameters: bytes - The bytes making out the class ID in big-endian format. | public String | toString() | public void | write(byte[] dst, int offset) |
LENGTH | final public static int LENGTH(Code) | | The number of bytes occupied by this object in the byte
stream.
|
bytes | protected byte[] bytes(Code) | | The bytes making out the class ID in correct order,
i.e. big-endian.
|
ClassID | public ClassID(byte[] src, int offset)(Code) | | Creates a
ClassID and reads its value from a byte
array.
Parameters: src - The byte array to read from. Parameters: offset - The offset of the first byte to read. |
ClassID | public ClassID()(Code) | | Creates a
ClassID and initializes its value with
0x00 bytes.
|
equals | public boolean equals(Object o)(Code) | | Checks whether this ClassID is equal to another
object.
Parameters: o - the object to compare this PropertySet with true if the objects are equal, elsefalse . |
getBytes | public byte[] getBytes()(Code) | | Gets the bytes making out the class ID. They are returned in
correct order, i.e. big-endian.
the bytes making out the class ID. |
length | public int length()(Code) | | The number of bytes occupied by this object in the bytestream. |
read | public byte[] read(byte[] src, int offset)(Code) | | Reads the class ID's value from a byte array by turning
little-endian into big-endian.
Parameters: src - The byte array to read from Parameters: offset - The offset within the src byte array A byte array containing the class ID. |
setBytes | public void setBytes(byte[] bytes)(Code) | | Sets the bytes making out the class ID.
Parameters: bytes - The bytes making out the class ID in big-endian format. Theyare copied without their order being changed. |
toString | public String toString()(Code) | | Returns a human-readable representation of the Class ID in standard
format "{xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}" .
String representation of the Class ID represented by this object. |
write | public void write(byte[] dst, int offset) throws ArrayStoreException(Code) | | Writes the class ID to a byte array in the
little-endian format.
Parameters: dst - The byte array to write to. Parameters: offset - The offset within the dst byte array. exception: ArrayStoreException - if there is not enough room for the classID 16 bytes in the byte array after the offset position. |
|
|