lempinen.neatseeker.core
Interface Indexer

All Known Implementing Classes:
AbstractIndexer, HTMLIndexer

public interface Indexer

Defines the interface for various Indexers.

The AbstractIndexer class provides a barebones implementation of this interface. Your indexers should inherit AbstractIndexer.

Version:
$Id: Indexer.java,v 1.5 2000/09/24 12:46:16 lempinen Exp $
See Also:
AbstractIndexer

Method Summary
 void add(Entry entry)
          Adds an entry in the index.
 Collector getCollector()
          Gets the Collector partner.
 Configuration getConfiguration()
          Returns the Configuration used by this Indexer.
 Repository getRepository()
          Returns the Repository used by this Indexer.
 void init(Configuration c)
          Initialises the Indexer if an empty constructor was used.
 void process(java.io.InputStream in, java.lang.String uri)
          Indexes the data in the InputStream.
 void setCollector(Collector c)
          Sets the Collector partner.
 void setConfiguration(Configuration c)
          Sets the Configuration used by this Indexer.
 void start()
          Starts the indexing process.
 

Method Detail

init

public void init(Configuration c)
          throws java.io.IOException
Initialises the Indexer if an empty constructor was used.

setCollector

public void setCollector(Collector c)
Sets the Collector partner.

getCollector

public Collector getCollector()
Gets the Collector partner.

setConfiguration

public void setConfiguration(Configuration c)
                      throws java.io.IOException
Sets the Configuration used by this Indexer.

getConfiguration

public Configuration getConfiguration()
Returns the Configuration used by this Indexer.

getRepository

public Repository getRepository()
Returns the Repository used by this Indexer.

add

public void add(Entry entry)
Adds an entry in the index.

start

public void start()
           throws java.io.IOException
Starts the indexing process.

process

public void process(java.io.InputStream in,
                    java.lang.String uri)
             throws java.io.IOException
Indexes the data in the InputStream.

The Collector partner must provide the Indexer with two arguments: the InputStream from which the data can be read as well as a URI that will be entered in the index.