|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.compass.core.impl.RefreshableCompass
public class RefreshableCompass
A wrapper around an actual implemenation of Compass that allows to rebuild it
after changes that are perfomed on the getConfig() configuration.
| Constructor Summary | |
|---|---|
RefreshableCompass(CompassConfiguration config,
InternalCompass compass)
|
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RefreshableCompass(CompassConfiguration config,
InternalCompass compass)
| Method Detail |
|---|
public CompassConfiguration getConfig()
CompassCompass.rebuild() should be called.
getConfig in interface Compass
public void rebuild()
throws CompassException
CompassIf 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 CompassCompassExceptionpublic Compass clone(CompassSettings addedSettings)
CompassCompass 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 CompassaddedSettings - The settings to be added.
public void addRebuildEventListener(RebuildEventListener eventListener)
addRebuildEventListener in interface InternalCompasspublic void removeRebuildEventListener(RebuildEventListener eventListener)
removeRebuildEventListener in interface InternalCompasspublic void start()
start in interface InternalCompasspublic void stop()
stop in interface InternalCompass
public CompassSession openSession(boolean allowCreate,
boolean checkClosed)
openSession in interface InternalCompass
public CompassSession openSession()
throws CompassException
CompassA 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 CompassCompassExceptionpublic String getName()
getName in interface InternalCompasspublic CompassSettings getSettings()
Compass
getSettings in interface CompassgetSettings in interface InternalCompasspublic CompassMapping getMapping()
getMapping in interface InternalCompasspublic ExecutorManager getExecutorManager()
getExecutorManager in interface InternalCompasspublic CompassMetaData getMetaData()
getMetaData in interface InternalCompasspublic SearchEngineFactory getSearchEngineFactory()
getSearchEngineFactory in interface InternalCompasspublic TransactionFactory getTransactionFactory()
getTransactionFactory in interface InternalCompasspublic LocalTransactionFactory getLocalTransactionFactory()
getLocalTransactionFactory in interface InternalCompasspublic ConverterLookup getConverterLookup()
getConverterLookup in interface InternalCompasspublic PropertyNamingStrategy getPropertyNamingStrategy()
getPropertyNamingStrategy in interface InternalCompasspublic CompassEventManager getEventManager()
getEventManager in interface InternalCompass
public void close()
throws CompassException
Compass
close in interface CompassCompassExceptionpublic ResourceFactory getResourceFactory()
Compass
getResourceFactory in interface Compasspublic SearchEngineOptimizer getSearchEngineOptimizer()
Compassstop or start), you
can check if the index need optimization, and you can optimize the index.
getSearchEngineOptimizer in interface Compasspublic SearchEngineIndexManager getSearchEngineIndexManager()
Compass
getSearchEngineIndexManager in interface Compasspublic SearchEngineSpellCheckManager getSpellCheckManager()
Compassnull if the spell check is not
enabled.
getSpellCheckManager in interface Compasspublic boolean isClosed()
Compasstrue if the Compass instance is already closed
isClosed in interface Compass
public Reference getReference()
throws NamingException
getReference in interface ReferenceableNamingException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||