org.compass.core.lucene.engine
Class LuceneSearchEngineFactory

java.lang.Object
  extended by org.compass.core.lucene.engine.LuceneSearchEngineFactory
All Implemented Interfaces:
SearchEngineFactory, InternalSearchEngineFactory

public class LuceneSearchEngineFactory
extends Object
implements InternalSearchEngineFactory

Author:
kimchy

Constructor Summary
LuceneSearchEngineFactory(PropertyNamingStrategy propertyNamingStrategy, CompassSettings settings, CompassMapping mapping, ExecutorManager executorManager)
           
 
Method Summary
 void close()
          Closes the factory.
 String getAliasProperty()
          Returns the name of the alias property.
 String getAllProperty()
          Returns the name for the all property.
 LuceneAnalyzerManager getAnalyzerManager()
           
 SearchEngineEventManager getEventManager()
           
 ExecutorManager getExecutorManager()
          Returns an executor manager allowing to execute tasks in an async manner as well as schedule tasks.
 String getExtendedAliasProperty()
          Returns the name of the extending alias property name.
 LuceneHighlighterManager getHighlighterManager()
           
 IndexDeletionPolicyFactory getIndexDeletionPolicyManager()
           
 SearchEngineIndexManager getIndexManager()
          Returns the index manager.
 LuceneSearchEngineIndexManager getLuceneIndexManager()
           
 LuceneSettings getLuceneSettings()
           
 CompassMapping getMapping()
           
 SearchEngineOptimizer getOptimizer()
          Returns the serach engine optimizer that was created by the factory.
 PropertyNamingStrategy getPropertyNamingStrategy()
          Returns the property naming strategy used by the search engine to create hidden properties.
 LuceneQueryParserManager getQueryParserManager()
           
 ResourceFactory getResourceFactory()
          Returns a resource factory allowing to create resources and properties.
 CompassSettings getSettings()
           
 SearchEngineSpellCheckManager getSpellCheckManager()
          Rerturns the specll checker manager (if enabled).
 TransactionContext getTransactionContext()
          Returns a transactional context that operations that (usually) operate on a different thread or outside of a transactional context should use.
 SearchEngine openSearchEngine(RuntimeCompassSettings runtimeSettings)
          Opens/Creates a light weight search engine to perform search engine operations.
 void setTransactionContext(TransactionContext transactionContext)
          Internal method.
 void start()
           
 void stop()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LuceneSearchEngineFactory

public LuceneSearchEngineFactory(PropertyNamingStrategy propertyNamingStrategy,
                                 CompassSettings settings,
                                 CompassMapping mapping,
                                 ExecutorManager executorManager)
Method Detail

close

public void close()
           throws SearchEngineException
Description copied from interface: SearchEngineFactory
Closes the factory.

Specified by:
close in interface SearchEngineFactory
Throws:
SearchEngineException

openSearchEngine

public SearchEngine openSearchEngine(RuntimeCompassSettings runtimeSettings)
Description copied from interface: SearchEngineFactory
Opens/Creates a light weight search engine to perform search engine operations.

Specified by:
openSearchEngine in interface SearchEngineFactory
Returns:
A new search engine session.

getTransactionContext

public TransactionContext getTransactionContext()
Description copied from interface: SearchEngineFactory
Returns a transactional context that operations that (usually) operate on a different thread or outside of a transactional context should use.

Specified by:
getTransactionContext in interface SearchEngineFactory

getExecutorManager

public ExecutorManager getExecutorManager()
Description copied from interface: SearchEngineFactory
Returns an executor manager allowing to execute tasks in an async manner as well as schedule tasks.

Specified by:
getExecutorManager in interface SearchEngineFactory

setTransactionContext

public void setTransactionContext(TransactionContext transactionContext)
Description copied from interface: InternalSearchEngineFactory
Internal method. Should be called before perfoming any operations with the search engine factory.

Specified by:
setTransactionContext in interface InternalSearchEngineFactory

start

public void start()
Specified by:
start in interface InternalSearchEngineFactory

stop

public void stop()
Specified by:
stop in interface InternalSearchEngineFactory

getResourceFactory

public ResourceFactory getResourceFactory()
Description copied from interface: SearchEngineFactory
Returns a resource factory allowing to create resources and properties.

Specified by:
getResourceFactory in interface SearchEngineFactory

getAliasProperty

public String getAliasProperty()
Description copied from interface: SearchEngineFactory
Returns the name of the alias property.

Specified by:
getAliasProperty in interface SearchEngineFactory
Returns:
The name of the alias property.

getExtendedAliasProperty

public String getExtendedAliasProperty()
Description copied from interface: SearchEngineFactory
Returns the name of the extending alias property name.

Specified by:
getExtendedAliasProperty in interface SearchEngineFactory

getAllProperty

public String getAllProperty()
Description copied from interface: SearchEngineFactory
Returns the name for the all property.

Specified by:
getAllProperty in interface SearchEngineFactory
Returns:
The name of the all property.

getMapping

public CompassMapping getMapping()

getPropertyNamingStrategy

public PropertyNamingStrategy getPropertyNamingStrategy()
Description copied from interface: SearchEngineFactory
Returns the property naming strategy used by the search engine to create hidden properties.

Specified by:
getPropertyNamingStrategy in interface SearchEngineFactory
Returns:
The property naming strategy used.

getOptimizer

public SearchEngineOptimizer getOptimizer()
Description copied from interface: SearchEngineFactory
Returns the serach engine optimizer that was created by the factory.

Specified by:
getOptimizer in interface SearchEngineFactory
Returns:
The search engine optimizer

getSpellCheckManager

public SearchEngineSpellCheckManager getSpellCheckManager()
Description copied from interface: SearchEngineFactory
Rerturns the specll checker manager (if enabled).

Specified by:
getSpellCheckManager in interface SearchEngineFactory

getIndexManager

public SearchEngineIndexManager getIndexManager()
Description copied from interface: SearchEngineFactory
Returns the index manager.

Specified by:
getIndexManager in interface SearchEngineFactory
Returns:
the search engine index manager.

getLuceneIndexManager

public LuceneSearchEngineIndexManager getLuceneIndexManager()

getLuceneSettings

public LuceneSettings getLuceneSettings()

getSettings

public CompassSettings getSettings()

getAnalyzerManager

public LuceneAnalyzerManager getAnalyzerManager()

getEventManager

public SearchEngineEventManager getEventManager()
Specified by:
getEventManager in interface SearchEngineFactory

getHighlighterManager

public LuceneHighlighterManager getHighlighterManager()
                                               throws SearchEngineException
Throws:
SearchEngineException

getQueryParserManager

public LuceneQueryParserManager getQueryParserManager()

getIndexDeletionPolicyManager

public IndexDeletionPolicyFactory getIndexDeletionPolicyManager()


Copyright (c) 2004-2008 The Compass Project.