org.tm4j.topicmap.index.text
Interface FullTextIndex

All Superinterfaces:
Index
All Known Implementing Classes:
LuceneIndexBase

public interface FullTextIndex
extends Index

Defines Methods for using a FullTextIndex. Returns { @link org.tm4j.topicmap.index.fulltext.QueryResult } objects containing org.tm4j.topicmap.index.fulltext.QueryHit`s the concrete syntax of the query depends on the concrete implementation

Author:
Harald Kuhn, harald_kuhn at users.sourceforge.net

Field Summary
static java.lang.String ID
          Lucene Field name for topicMapObject Idīs
static java.lang.String LINK
          Lucene Field name for indexed links (occurrence.datalocator)
static java.lang.String PARENT_ID
          Lucene Field name for topicMapObject parentIdīs
static java.lang.String VALUE
          Lucene Field name for indexed values (occurrence.data, basename.value etc.)
 
Method Summary
 QueryResult findByText(java.lang.String query, boolean includeURIs)
          This causes the FullTextIndex to be queried for the given query.
 
Methods inherited from interface org.tm4j.topicmap.index.Index
close, isOpen, open, reindex
 

Field Detail

ID

public static final java.lang.String ID
Lucene Field name for topicMapObject Idīs

See Also:
Constant Field Values

PARENT_ID

public static final java.lang.String PARENT_ID
Lucene Field name for topicMapObject parentIdīs

See Also:
Constant Field Values

VALUE

public static final java.lang.String VALUE
Lucene Field name for indexed values (occurrence.data, basename.value etc.)

See Also:
Constant Field Values

LINK

public static final java.lang.String LINK
Lucene Field name for indexed links (occurrence.datalocator)

See Also:
Constant Field Values
Method Detail

findByText

public QueryResult findByText(java.lang.String query,
                              boolean includeURIs)
                       throws IndexException
This causes the FullTextIndex to be queried for the given query. The Hits are returned in a QueryResult object. The queries have to follow the syntax of the FullTextEngine used inside the implementation If no index is available or the index is corrupted, an IndexException is thrown

Parameters:
query - the Query String following the FullTextEngine Query Syntax
includeURIs - wether to also index uriīs
Returns:
a QueryResult containing all Hits encoutered by this query
Throws:
IndexException - thrown if no index is available or it is corrupted