org.galagosearch.core.index
Class PositionIndexReader
java.lang.Object
org.galagosearch.core.index.PositionIndexReader
- All Implemented Interfaces:
- StructuredIndexPartReader
public class PositionIndexReader
- extends java.lang.Object
- implements StructuredIndexPartReader
Reads a simple positions-based index, where each inverted list in the
index contains both term count information and term position information.
The term counts data is stored separately from term position information for
faster query processing when no positions are needed.
For now, the iterator loads everything into memory before starting query
processing, which is not a workable solution for larger collections.
- Author:
- trevor
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PositionIndexReader
public PositionIndexReader(IndexReader reader)
throws java.io.IOException
- Throws:
java.io.IOException
PositionIndexReader
public PositionIndexReader(java.lang.String pathname)
throws java.io.FileNotFoundException,
java.io.IOException
- Throws:
java.io.FileNotFoundException
java.io.IOException
getIterator
public PositionIndexReader.Iterator getIterator()
throws java.io.IOException
- Returns an iterator pointing at the first term in the index.
- Specified by:
getIterator in interface StructuredIndexPartReader
- Throws:
java.io.IOException
getTermExtents
public PositionIndexReader.Iterator getTermExtents(java.lang.String term)
throws java.io.IOException
- Returns an iterator pointing at the specified term, or
null if the term doesn't exist in the inverted file.
- Throws:
java.io.IOException
close
public void close()
throws java.io.IOException
- Specified by:
close in interface StructuredIndexPartReader
- Throws:
java.io.IOException
getNodeTypes
public java.util.Map<java.lang.String,NodeType> getNodeTypes()
- Specified by:
getNodeTypes in interface StructuredIndexPartReader
getIterator
public IndexIterator getIterator(Node node)
throws java.io.IOException
- Specified by:
getIterator in interface StructuredIndexPartReader
- Throws:
java.io.IOException
Copyright © 2009. All Rights Reserved.