|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.compass.core.impl.DefaultCompass
public class DefaultCompass
Field Summary | |
---|---|
protected CompassSettings |
settings
|
Constructor Summary | |
---|---|
DefaultCompass(CompassMapping mapping,
ConverterLookup converterLookup,
CompassMetaData compassMetaData,
PropertyNamingStrategy propertyNamingStrategy,
CompassSettings settings,
LuceneSearchEngineFactory searchEngineFactory)
|
|
DefaultCompass(CompassMapping mapping,
ConverterLookup converterLookup,
CompassMetaData compassMetaData,
PropertyNamingStrategy propertyNamingStrategy,
ExecutorManager executorManager,
CompassSettings settings)
|
|
DefaultCompass(CompassMapping mapping,
ConverterLookup converterLookup,
CompassMetaData compassMetaData,
PropertyNamingStrategy propertyNamingStrategy,
ExecutorManager executorManager,
CompassSettings settings,
boolean duplicate)
|
|
DefaultCompass(CompassMapping mapping,
ConverterLookup converterLookup,
CompassMetaData compassMetaData,
PropertyNamingStrategy propertyNamingStrategy,
ExecutorManager executorManager,
CompassSettings settings,
boolean duplicate,
LuceneSearchEngineFactory searchEngineFactory)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected CompassSettings settings
Constructor Detail |
---|
public DefaultCompass(CompassMapping mapping, ConverterLookup converterLookup, CompassMetaData compassMetaData, PropertyNamingStrategy propertyNamingStrategy, ExecutorManager executorManager, CompassSettings settings) throws CompassException
CompassException
public DefaultCompass(CompassMapping mapping, ConverterLookup converterLookup, CompassMetaData compassMetaData, PropertyNamingStrategy propertyNamingStrategy, ExecutorManager executorManager, CompassSettings settings, boolean duplicate) throws CompassException
CompassException
public DefaultCompass(CompassMapping mapping, ConverterLookup converterLookup, CompassMetaData compassMetaData, PropertyNamingStrategy propertyNamingStrategy, CompassSettings settings, LuceneSearchEngineFactory searchEngineFactory) throws CompassException
CompassException
public DefaultCompass(CompassMapping mapping, ConverterLookup converterLookup, CompassMetaData compassMetaData, PropertyNamingStrategy propertyNamingStrategy, ExecutorManager executorManager, CompassSettings settings, boolean duplicate, LuceneSearchEngineFactory searchEngineFactory) throws CompassException
CompassException
Method Detail |
---|
public CompassConfiguration getConfig()
Compass
Compass.rebuild()
should be called.
getConfig
in interface Compass
public void rebuild()
Compass
If the rebuild fails, the Compass instance can still work and it will be based on the latest valid Compass instance that was rebuilt.
rebuild
in interface Compass
public void addRebuildEventListener(RebuildEventListener eventListener)
addRebuildEventListener
in interface InternalCompass
public void removeRebuildEventListener(RebuildEventListener eventListener)
removeRebuildEventListener
in interface InternalCompass
public Compass clone(CompassSettings addedSettings)
Compass
Compass
instance. The added settings will merged with the current
compass settings, and control the creation of the new Compass.
Note, that the new instance will not be registered with JNDI, as well as not start the optimizer.
clone
in interface Compass
addedSettings
- The settings to be added.
public String getName()
getName
in interface InternalCompass
public ResourceFactory getResourceFactory()
Compass
getResourceFactory
in interface Compass
public CompassMapping getMapping()
getMapping
in interface InternalCompass
public ExecutorManager getExecutorManager()
getExecutorManager
in interface InternalCompass
public CompassEventManager getEventManager()
getEventManager
in interface InternalCompass
public CompassSession openSession()
Compass
A transactional bound session is bounded to the transaction when calling the CompassSession.beginTransaction() or if Compass tries to automatically join an already running transaction (see next paragraph).
If creating a new session, will try to automatically join an existing outer transaction. An outer transaction might be an already running Compass local transaction, or an external transaciton (JTA or Spring for example). In such cases, there is no need to perform any transaction managment code (begin or commit/rollback transaction) or closing the opened session. Compass will also bind the session to the same transaction if an outer transaction exists. Note, when doing so, the mentioned code will have to always be excuted within an already running transaction.
openSession
in interface Compass
public CompassSession openSession(boolean allowCreate)
public CompassSession openSession(boolean allowCreate, boolean checkClosed)
openSession
in interface InternalCompass
public void start()
start
in interface InternalCompass
public void stop()
stop
in interface InternalCompass
public void close()
Compass
close
in interface Compass
public boolean isClosed()
Compass
true
if the Compass instance is already closed
isClosed
in interface Compass
public Reference getReference() throws NamingException
getReference
in interface Referenceable
NamingException
public CompassSettings getSettings()
Compass
getSettings
in interface Compass
getSettings
in interface InternalCompass
public SearchEngineOptimizer getSearchEngineOptimizer()
Compass
stop
or start
), you
can check if the index need optimization, and you can optimize the index.
getSearchEngineOptimizer
in interface Compass
public SearchEngineIndexManager getSearchEngineIndexManager()
Compass
getSearchEngineIndexManager
in interface Compass
public SearchEngineSpellCheckManager getSpellCheckManager()
Compass
null
if the spell check is not
enabled.
getSpellCheckManager
in interface Compass
public SearchEngineFactory getSearchEngineFactory()
getSearchEngineFactory
in interface InternalCompass
public CompassMetaData getMetaData()
getMetaData
in interface InternalCompass
public TransactionFactory getTransactionFactory()
getTransactionFactory
in interface InternalCompass
public LocalTransactionFactory getLocalTransactionFactory()
getLocalTransactionFactory
in interface InternalCompass
public ConverterLookup getConverterLookup()
getConverterLookup
in interface InternalCompass
public PropertyNamingStrategy getPropertyNamingStrategy()
getPropertyNamingStrategy
in interface InternalCompass
protected void finalize() throws Throwable
finalize
in class Object
Throwable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |