|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectokapi.util.OkapiSearchUtils.Searcher
public static class OkapiSearchUtils.Searcher
class Searcher Class to perform searching and incremental index updates. To perform a search: - set the index directory with OkapiSearchUtils.setIndexPathsFromContext() or OkapiSearchUtils.setIndexPaths() - get a Searcher with OkapiSearchUtils.getSearcher() - call doSearch() - release the Searcher with OkapiSearchUtils.releaseSearcher() To update the index: - set the index directory with OkapiSearchUtils.setIndexPathsFromContext() or OkapiSearchUtils.setIndexPaths() - get a Searcher with OkapiSearchUtils.getSearcher() - call doUpdate() - release the Searcher with OkapiSearchUtils.releaseSearcher() Note that the Searcher always needs to be released after use.
Method Summary | |
---|---|
java.util.Vector |
doSearch(java.lang.String searchText,
java.lang.String nexusPath,
java.lang.String urlRoot)
doSearch Performs a search for the specified search terms in the specified nexus. |
java.util.Vector |
doShowIndex(java.lang.String urlRoot)
doShowIndex Returns everything in the index (in every nexus). |
java.util.Vector |
doShowNexus(java.lang.String nexusPath,
java.lang.String urlRoot)
doShowNexus Performs a search for all documents in the specified nexus. |
boolean |
doUpdate(OkapiArc arc,
java.lang.String nexusPath,
java.lang.String arcPath,
boolean delete)
doUpdate -- NOT TESTED Adds, updates, or deletes the arc's index entry in the current working index. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public java.util.Vector doSearch(java.lang.String searchText, java.lang.String nexusPath, java.lang.String urlRoot) throws java.lang.Exception
searchText
- search term(s)nexusPath
- path of current nexus (must be matched during search)urlRoot
- root of URL - arc path is appended to this to form the
href
java.lang.Exception
public java.util.Vector doShowNexus(java.lang.String nexusPath, java.lang.String urlRoot) throws java.lang.Exception
nexusPath
- path of current nexus (must be matched during search)urlRoot
- root of URL - arc path is appended to this to form the
href
java.lang.Exception
public java.util.Vector doShowIndex(java.lang.String urlRoot) throws java.lang.Exception
urlRoot
- root of URL - nexus and arc path are appended to this to
form the href
java.lang.Exception
public boolean doUpdate(OkapiArc arc, java.lang.String nexusPath, java.lang.String arcPath, boolean delete)
arc
- Arc to delete or re-index.nexusPath
- Cumulative path to the arc's nexus (i.e. "", "/OKI",
"/OKI/searchdev").arcPath
- Cumulative path to the arc (i.e.
"/courseMaterial/topics/topic2").delete
- If true, arc is deleted from index but not reindexed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |