|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.basex.util.Set
org.basex.index.Names
public final class Names
This class indexes and organizes the tags or attribute names, used in an XML document.
Field Summary | |
---|---|
boolean |
uptodate
Statistics flag. |
Fields inherited from class org.basex.util.Set |
---|
size |
Constructor Summary | |
---|---|
Names()
Empty Constructor. |
|
Names(DataInput in)
Constructor, specifying an input file. |
Method Summary | |
---|---|
int |
counter(int id)
Returns the tag counter (number of indexed keys). |
void |
finish(DataOutput out)
Writes the names to the specified output stream. |
int |
index(byte[] k,
byte[] v)
Indexes a name and returns its unique id. |
void |
index(int i,
byte[] v)
Evaluates the value for the specified key id. |
byte[] |
info()
Returns index information. |
void |
init()
Initializes the statistics. |
boolean |
noLeaf(int id)
Returns node flag for the specified id. |
void |
noleaf(int id,
boolean l)
Sets node flag for the specified id. |
StatsKey |
stat(int id)
Returns the statistics for the specified key id. |
Methods inherited from class org.basex.util.Set |
---|
add, delete, id, key, keys, size |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public boolean uptodate
Constructor Detail |
---|
public Names()
public Names(DataInput in) throws java.io.IOException
in
- input stream
java.io.IOException
- I/O exceptionMethod Detail |
---|
public void init()
public int index(byte[] k, byte[] v)
k
- name to be foundv
- value, evaluated in statistics
public void index(int i, byte[] v)
i
- key idv
- value, used for statisticspublic void finish(DataOutput out) throws java.io.IOException
out
- output stream
java.io.IOException
- in case the file could not be writtenpublic int counter(int id)
id
- token id
public void noleaf(int id, boolean l)
id
- token idl
- node flagpublic StatsKey stat(int id)
id
- id
public boolean noLeaf(int id)
id
- token id
public byte[] info()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |