gate.creole.ir
Interface IndexManager

All Known Implementing Classes:
LuceneIndexManager

public interface IndexManager


Method Summary
 void createIndex()
          Creates index directory and indexing all documents in the corpus.
 void deleteIndex()
          Delete all index files and directories in index location.
 Corpus getCorpus()
          Gets the corpus this index manages will index.
 IndexDefinition getIndexDefinition()
          Gets the index definition for this index manager.
 void optimizeIndex()
          Optimize the existing index
 void setCorpus(Corpus corpus)
          Sets the corpus this index manages will index.
 void setIndexDefinition(IndexDefinition indexDefinition)
          Sets the index definition for this index manager.
 void sync(List added, List removed, List changed)
          Reindexing changed documents, removing removed documents and add to the index new corpus documents.
 

Method Detail

getCorpus

Corpus getCorpus()
Gets the corpus this index manages will index.

Returns:
a Corpus value;

setCorpus

void setCorpus(Corpus corpus)
Sets the corpus this index manages will index.

Parameters:
corpus - a Corpus value;

getIndexDefinition

IndexDefinition getIndexDefinition()
Gets the index definition for this index manager.

Returns:
a IndexDefinition value.

setIndexDefinition

void setIndexDefinition(IndexDefinition indexDefinition)
Sets the index definition for this index manager.

Parameters:
indexDefinition - a IndexDefinition value.

createIndex

void createIndex()
                 throws IndexException
Creates index directory and indexing all documents in the corpus.

Throws:
IndexException

optimizeIndex

void optimizeIndex()
                   throws IndexException
Optimize the existing index

Throws:
IndexException

deleteIndex

void deleteIndex()
                 throws IndexException
Delete all index files and directories in index location.

Throws:
IndexException

sync

void sync(List added,
          List removed,
          List changed)
          throws IndexException
Reindexing changed documents, removing removed documents and add to the index new corpus documents.

Throws:
IndexException