@Component(role=SearchEngine.class) public class DefaultSearchEngine extends org.codehaus.plexus.logging.AbstractLogEnabled implements SearchEngine
| Constructor and Description |
|---|
DefaultSearchEngine() |
| Modifier and Type | Method and Description |
|---|---|
protected org.apache.lucene.search.TopScoreDocCollector |
doSearchWithCeiling(AbstractSearchRequest request,
org.apache.lucene.search.IndexSearcher indexSearcher,
org.apache.lucene.search.Query query) |
FlatSearchResponse |
forceSearchFlatPaged(FlatSearchRequest request,
Collection<IndexingContext> indexingContexts)
Do the search in all contexts, no matter if the context is searchable or not
|
GroupedSearchResponse |
forceSearchGrouped(GroupedSearchRequest request,
Collection<IndexingContext> indexingContexts)
Do the search in all contexts, no matter if the context is searchable or not
|
IteratorSearchResponse |
forceSearchIteratorPaged(IteratorSearchRequest request,
Collection<IndexingContext> indexingContexts)
Do the search in all contexts, no matter if the context is searchable or not
|
protected NexusIndexMultiReader |
getMergedIndexReader(Collection<IndexingContext> indexingContexts,
boolean ignoreContext)
Locks down participating contexts, and returns a "merged" reader of them.
|
protected List<IndexingContext> |
getParticipatingContexts(Collection<IndexingContext> indexingContexts,
boolean ignoreContext)
Returns the list of participating contexts.
|
protected int |
getTopDocsCollectorHitNum(AbstractSearchRequest request,
int ceiling) |
Set<ArtifactInfo> |
searchFlat(Comparator<ArtifactInfo> artifactInfoComparator,
Collection<IndexingContext> indexingContexts,
org.apache.lucene.search.Query query)
Deprecated.
|
Set<ArtifactInfo> |
searchFlat(Comparator<ArtifactInfo> artifactInfoComparator,
IndexingContext indexingContext,
org.apache.lucene.search.Query query)
Deprecated.
|
protected int |
searchFlat(FlatSearchRequest req,
Collection<ArtifactInfo> result,
List<IndexingContext> participatingContexts,
org.apache.lucene.search.Query query) |
FlatSearchResponse |
searchFlatPaged(FlatSearchRequest request,
Collection<IndexingContext> indexingContexts)
Do the search only on searchable contexts
|
protected FlatSearchResponse |
searchFlatPaged(FlatSearchRequest request,
Collection<IndexingContext> indexingContexts,
boolean ignoreContext) |
GroupedSearchResponse |
searchGrouped(GroupedSearchRequest request,
Collection<IndexingContext> indexingContexts)
Do the search only on searchable contexts
|
protected GroupedSearchResponse |
searchGrouped(GroupedSearchRequest request,
Collection<IndexingContext> indexingContexts,
boolean ignoreContext) |
protected int |
searchGrouped(GroupedSearchRequest req,
Map<String,ArtifactInfoGroup> result,
Grouping grouping,
List<IndexingContext> participatingContexts,
org.apache.lucene.search.Query query) |
IteratorSearchResponse |
searchIteratorPaged(IteratorSearchRequest request,
Collection<IndexingContext> indexingContexts)
Do the search only on searchable contexts
|
@Deprecated public Set<ArtifactInfo> searchFlat(Comparator<ArtifactInfo> artifactInfoComparator, IndexingContext indexingContext, org.apache.lucene.search.Query query) throws IOException
searchFlat in interface SearchEngineIOException@Deprecated public Set<ArtifactInfo> searchFlat(Comparator<ArtifactInfo> artifactInfoComparator, Collection<IndexingContext> indexingContexts, org.apache.lucene.search.Query query) throws IOException
searchFlat in interface SearchEngineIOExceptionpublic FlatSearchResponse searchFlatPaged(FlatSearchRequest request, Collection<IndexingContext> indexingContexts) throws IOException
SearchEnginesearchFlatPaged in interface SearchEngineIOExceptionpublic FlatSearchResponse forceSearchFlatPaged(FlatSearchRequest request, Collection<IndexingContext> indexingContexts) throws IOException
SearchEngineforceSearchFlatPaged in interface SearchEngineIOExceptionprotected FlatSearchResponse searchFlatPaged(FlatSearchRequest request, Collection<IndexingContext> indexingContexts, boolean ignoreContext) throws IOException
IOExceptionpublic GroupedSearchResponse searchGrouped(GroupedSearchRequest request, Collection<IndexingContext> indexingContexts) throws IOException
SearchEnginesearchGrouped in interface SearchEngineIOExceptionpublic GroupedSearchResponse forceSearchGrouped(GroupedSearchRequest request, Collection<IndexingContext> indexingContexts) throws IOException
SearchEngineforceSearchGrouped in interface SearchEngineIOExceptionprotected GroupedSearchResponse searchGrouped(GroupedSearchRequest request, Collection<IndexingContext> indexingContexts, boolean ignoreContext) throws IOException
IOExceptionprotected int searchFlat(FlatSearchRequest req, Collection<ArtifactInfo> result, List<IndexingContext> participatingContexts, org.apache.lucene.search.Query query) throws IOException
IOExceptionprotected int searchGrouped(GroupedSearchRequest req, Map<String,ArtifactInfoGroup> result, Grouping grouping, List<IndexingContext> participatingContexts, org.apache.lucene.search.Query query) throws IOException
IOExceptionpublic IteratorSearchResponse searchIteratorPaged(IteratorSearchRequest request, Collection<IndexingContext> indexingContexts) throws IOException
SearchEnginesearchIteratorPaged in interface SearchEngineIOExceptionpublic IteratorSearchResponse forceSearchIteratorPaged(IteratorSearchRequest request, Collection<IndexingContext> indexingContexts) throws IOException
SearchEngineforceSearchIteratorPaged in interface SearchEngineIOExceptionprotected org.apache.lucene.search.TopScoreDocCollector doSearchWithCeiling(AbstractSearchRequest request, org.apache.lucene.search.IndexSearcher indexSearcher, org.apache.lucene.search.Query query) throws IOException
IOExceptionprotected List<IndexingContext> getParticipatingContexts(Collection<IndexingContext> indexingContexts, boolean ignoreContext)
protected NexusIndexMultiReader getMergedIndexReader(Collection<IndexingContext> indexingContexts, boolean ignoreContext) throws IOException
indexingContexts - ignoreContext - IOExceptionprotected int getTopDocsCollectorHitNum(AbstractSearchRequest request, int ceiling)
Copyright © 2002-2013 The Apache Software Foundation. All Rights Reserved.