|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object loci.formats.codec.LZWTreeNode
public class LZWTreeNode
An LZW-compression helper class for building a symbol table in tree format.
Field Summary | |
---|---|
protected LZWTreeNode[] |
children
List of up to 256 children. |
protected int |
theCode
Code corresponding to this node. |
Constructor Summary | |
---|---|
LZWTreeNode(int code)
Constructs a new LZW symbol tree node. |
Method Summary | |
---|---|
void |
addChild(int index,
LZWTreeNode node)
Sets this node's indexth child to match the given node. |
void |
addTableEntry(ByteVector string,
int code)
Adds the given code for the specified byte sequence. |
int |
codeFromString(ByteVector string)
Gets the code for the given byte sequence, or -1 if none. |
LZWTreeNode |
getChild(byte index)
Gets this node's indexth child. |
int |
getCode()
Gets the code corresponding to this node. |
void |
initialize()
Initializes this node as the root of the symbol table. |
LZWTreeNode |
nodeFromString(ByteVector string)
Gets the node for the given byte sequence, or null if none. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected LZWTreeNode[] children
protected int theCode
Constructor Detail |
---|
public LZWTreeNode(int code)
Method Detail |
---|
public void initialize()
public int getCode()
public LZWTreeNode getChild(byte index)
public void addChild(int index, LZWTreeNode node)
public int codeFromString(ByteVector string)
public LZWTreeNode nodeFromString(ByteVector string)
public void addTableEntry(ByteVector string, int code)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |