org.basex.index
Class Values

java.lang.Object
  extended by org.basex.index.Values
All Implemented Interfaces:
Index

public final class Values
extends Object
implements Index

This class provides access to attribute values and text contents stored on disk.

Author:
Workgroup DBIS, University of Konstanz 2005-10, ISC License, Christian Gruen

Constructor Summary
Values(Data d, boolean txt)
          Constructor, initializing the index structure.
 
Method Summary
 void close()
          Closes the index.
 IndexIterator ids(IndexToken tok)
          Returns an iterator for the index results.
 byte[] info()
          Returns information on the index structure.
 byte[] nextPres()
          Returns next pre values.
 int nrIDs(IndexToken it)
          Returns the (approximate/estimated) number of ids for the specified token.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Values

public Values(Data d,
              boolean txt)
       throws IOException
Constructor, initializing the index structure.

Parameters:
d - data reference
txt - value type (texts/attributes)
Throws:
IOException - IO Exception
Method Detail

info

public byte[] info()
Description copied from interface: Index
Returns information on the index structure.

Specified by:
info in interface Index
Returns:
info

ids

public IndexIterator ids(IndexToken tok)
Description copied from interface: Index
Returns an iterator for the index results.

Specified by:
ids in interface Index
Parameters:
tok - token to be found
Returns:
ids

nrIDs

public int nrIDs(IndexToken it)
Description copied from interface: Index
Returns the (approximate/estimated) number of ids for the specified token.

Specified by:
nrIDs in interface Index
Parameters:
it - token to be found
Returns:
number of ids

nextPres

public byte[] nextPres()
Returns next pre values.

Returns:
compressed pre values

close

public void close()
           throws IOException
Description copied from interface: Index
Closes the index.

Specified by:
close in interface Index
Throws:
IOException - I/O exception