Package lucee.runtime.search
Interface SearchEngine
-
public interface SearchEngine
interface for a Search Engine
-
-
Field Summary
Fields Modifier and Type Field Description static boolean
ALLOW_OVERWRITE
overwrite allowedstatic boolean
DENY_OVERWRITE
overwrite denied
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description SearchCollection
createCollection(java.lang.String name, Resource path, java.lang.String language, boolean allowOverwrite)
Creates a new Collection and Store it (creating always a spellindex)SearchData
createSearchData(int suggestionMax)
SearchCollection
getCollectionByName(java.lang.String name)
returns a collection by nameQuery
getCollectionsAsQuery()
Resource
getDirectory()
java.lang.String
getDisplayName()
void
init(Config config, Resource searchDir)
-
-
-
Field Detail
-
ALLOW_OVERWRITE
static final boolean ALLOW_OVERWRITE
overwrite allowed- See Also:
- Constant Field Values
-
DENY_OVERWRITE
static final boolean DENY_OVERWRITE
overwrite denied- See Also:
- Constant Field Values
-
-
Method Detail
-
init
void init(Config config, Resource searchDir) throws java.io.IOException, SearchException
- Throws:
java.io.IOException
SearchException
-
getCollectionByName
SearchCollection getCollectionByName(java.lang.String name) throws SearchException
returns a collection by name- Parameters:
name
- name of the desired collection (case insensitive)- Returns:
- returns lucene collection object matching name
- Throws:
SearchException
- if no matching Collection exist
-
getCollectionsAsQuery
Query getCollectionsAsQuery() throws SearchException
- Returns:
- returns all collections as a query object
- Throws:
SearchException
- if no matching Collection exist
-
createCollection
SearchCollection createCollection(java.lang.String name, Resource path, java.lang.String language, boolean allowOverwrite) throws SearchException
Creates a new Collection and Store it (creating always a spellindex)- Parameters:
name
- The Name of the Collectionpath
- the path to storelanguage
- The language of the collectionallowOverwrite
- Allow Overwrite- Returns:
- New SearchCollection
- Throws:
SearchException
- Search Exception
-
getDirectory
Resource getDirectory()
- Returns:
- returns the directory of the search storage
-
getDisplayName
java.lang.String getDisplayName()
- Returns:
- returns the Name of the search engine to display in admin
-
createSearchData
SearchData createSearchData(int suggestionMax)
-
-