|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface LuceneSearchEngineStore
Manages the mapping between aliases and their repective sub indexes. A Acts
as an abstration layer on top of the actual Lucene Directory
creation.
Method Summary | |
---|---|
String[] |
calcSubIndexes(String[] subIndexes,
String[] aliases)
Returns the sub indexes that intersect with the given sub indexes and aliases provided. |
String[] |
calcSubIndexes(String[] subIndexes,
String[] aliases,
Class[] types)
Returns the sub indexes the intersect with the given sub indexes and aliases provided. |
void |
cleanIndex(String subIndex)
Cleans the sub index. |
void |
close()
Closes the store. |
void |
copyFrom(String subIndex,
LuceneSearchEngineStore searchEngineStore)
Copies the index from the given store into the current store. |
void |
copyFrom(String subContext,
String subIndex,
LuceneSearchEngineStore searchEngineStore)
Copies the index from the given store into the current store. |
void |
createIndex()
Creates the index (if it is already exists, delets it first). |
void |
deleteIndex()
Deletes the index. |
void |
deleteIndex(String subIndex)
Deletes the index for the given sub index. |
void |
deleteIndex(String subContext,
String subIndex)
Deletes the index for the given sub context and sub index. |
String[] |
getAliasesBySubIndex(String subIndex)
Returns the list of aliases that are mapped for a given sub index. |
String |
getDefaultSubContext()
Returns the default sub context associated with this store. |
int |
getNumberOfAliasesBySubIndex(String subIndex)
Returns the number of aliases that map to the given sub index. |
String[] |
getSubIndexes()
Returns all the sub indexes defined within the store. |
boolean |
indexExists()
Returns true if one of the sub indexes index does exists. |
boolean |
indexExists(String subIndex)
Returns true if the sub index index does exists as a legal Lucene index. |
boolean |
isLocked()
Returns true if any sub index is locked. |
boolean |
isLocked(String subIndex)
Returns true if the sub index is locked (both Lucene write and commit locks). |
boolean |
isUseCompoundFile()
Should we use the compound file format or not. |
Directory |
openDirectory(String subIndex)
Returns the directory that match the given sub index. |
Directory |
openDirectory(String subContext,
String subIndex)
Returns the directory that match the given sub index. |
void |
performScheduledTasks()
Performs any scheduled tasks, managed by the index manager. |
String[] |
polyCalcSubIndexes(String[] subIndexes,
String[] aliases,
Class[] types)
Returns the sub indexes that intersect with the given sub indexes, aliases and types. |
void |
registerEventListeners(SearchEngine searchEngine,
SearchEngineEventManager eventManager)
A callback to register event listeners when a SearchEngine is
created. |
void |
releaseLock(String subIndex)
Releases the lock for the given sub index. |
void |
releaseLocks()
Releases all the locks on all the sub indexes. |
boolean |
requiresAsyncTransactionalContext()
Returns true if a transaction needs to be started when performing operations
with this store. |
boolean |
subIndexExists(String subIndex)
Returns true if the sub index exists. |
String |
suggestedIndexDeletionPolicy()
Returns the suggested index deletion policy for the given store. |
boolean |
supportsConcurrentCommits()
Returns true if this store supprots concurrent commits. |
boolean |
supportsConcurrentOperations()
Returns true if this store supports concurrent operations. |
boolean |
verifyIndex()
Verify that the index exists. |
Method Detail |
---|
void close()
void performScheduledTasks()
String[] getSubIndexes()
boolean subIndexExists(String subIndex)
true
if the sub index exists.
int getNumberOfAliasesBySubIndex(String subIndex)
String[] getAliasesBySubIndex(String subIndex)
Directory openDirectory(String subIndex) throws SearchEngineException
SearchEngineException
Directory openDirectory(String subContext, String subIndex) throws SearchEngineException
SearchEngineException
boolean isLocked() throws SearchEngineException
true
if any sub index is locked.
SearchEngineException
boolean isLocked(String subIndex) throws SearchEngineException
true
if the sub index is locked (both Lucene write and commit locks).
SearchEngineException
void releaseLocks() throws SearchEngineException
SearchEngineException
void releaseLock(String subIndex) throws SearchEngineException
SearchEngineException
void deleteIndex() throws SearchEngineException
SearchEngineException
void deleteIndex(String subIndex) throws SearchEngineException
SearchEngineException
void deleteIndex(String subContext, String subIndex) throws SearchEngineException
SearchEngineException
void cleanIndex(String subIndex) throws SearchEngineException
SearchEngineException
void createIndex() throws SearchEngineException
SearchEngineException
boolean verifyIndex() throws SearchEngineException
SearchEngineException
boolean indexExists() throws SearchEngineException
true
if one of the sub indexes index does exists.
SearchEngineException
boolean indexExists(String subIndex) throws SearchEngineException
true
if the sub index index does exists as a legal Lucene index.
SearchEngineException
String[] calcSubIndexes(String[] subIndexes, String[] aliases, Class[] types)
String[] polyCalcSubIndexes(String[] subIndexes, String[] aliases, Class[] types)
String[] calcSubIndexes(String[] subIndexes, String[] aliases)
null
,
return all the sub indexes.
void copyFrom(String subContext, String subIndex, LuceneSearchEngineStore searchEngineStore) throws SearchEngineException
SearchEngineException
void copyFrom(String subIndex, LuceneSearchEngineStore searchEngineStore) throws SearchEngineException
SearchEngineException
String getDefaultSubContext()
void registerEventListeners(SearchEngine searchEngine, SearchEngineEventManager eventManager)
SearchEngine
is
created.
searchEngine
- The search engine createdeventManager
- The event manager to register events withboolean requiresAsyncTransactionalContext()
true
if a transaction needs to be started when performing operations
with this store.
boolean supportsConcurrentOperations()
true
if this store supports concurrent operations.
boolean supportsConcurrentCommits()
true
if this store supprots concurrent commits.
boolean isUseCompoundFile()
String suggestedIndexDeletionPolicy()
null
if globabl settings should be applied.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |