org.cdlib.xtf.util
Class TagChars

Object
  extended by TagChars

public class TagChars
extends Object

Class that represents a slice of a block, for quick access to byte-level strings without object allocation.


Field Summary
(package private)  byte[] block
           
(package private)  int length
           
(package private)  int offset
           
 
Constructor Summary
TagChars()
           
 
Method Summary
 char charAt(int index)
           
 int indexOf(char c)
           
 int length()
           
 int prefixMatch(TagChars other)
          Determines how many characters match at the start of two sequences
 String toString()
           
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

length

int length

block

byte[] block

offset

int offset
Constructor Detail

TagChars

public TagChars()
Method Detail

charAt

public final char charAt(int index)

length

public final int length()

indexOf

public final int indexOf(char c)

prefixMatch

public final int prefixMatch(TagChars other)
Determines how many characters match at the start of two sequences


toString

public final String toString()
Overrides:
toString in class Object