Class InnerHitsContext.InnerHitSubContext
java.lang.Object
org.elasticsearch.search.internal.SearchContext
org.elasticsearch.search.internal.FilteredSearchContext
org.elasticsearch.search.internal.SubSearchContext
org.elasticsearch.search.fetch.subphase.InnerHitsContext.InnerHitSubContext
- All Implemented Interfaces:
java.io.Closeable,java.lang.AutoCloseable,Releasable
- Enclosing class:
- InnerHitsContext
public abstract static class InnerHitsContext.InnerHitSubContext extends SubSearchContext
-
Field Summary
Fields Modifier and Type Field Description protected SearchContextcontextFields inherited from class org.elasticsearch.search.internal.SearchContext
DEFAULT_TERMINATE_AFTER, DEFAULT_TRACK_TOTAL_HITS_UP_TO, TRACK_TOTAL_HITS_ACCURATE, TRACK_TOTAL_HITS_DISABLED -
Constructor Summary
Constructors Modifier Constructor Description protectedInnerHitSubContext(java.lang.String name, SearchContext context) -
Method Summary
Modifier and Type Method Description protected org.apache.lucene.search.WeightgetInnerHitQueryWeight()java.lang.StringgetName()UidgetRootId()The _id of the root document.SourceLookupgetRootLookup()A source lookup for the root document.InnerHitsContextinnerHits()SearchContextparentSearchContext()voidsetChildInnerHits(java.util.Map<java.lang.String,InnerHitsContext.InnerHitSubContext> childInnerHits)voidsetRootId(Uid rootId)voidsetRootLookup(SourceLookup rootLookup)abstract TopDocsAndMaxScoretopDocs(SearchHit hit)Methods inherited from class org.elasticsearch.search.internal.SubSearchContext
aggregations, buildFilteredQuery, collapse, docIdsToLoad, docIdsToLoad, docIdsToLoadFrom, docIdsToLoadSize, doClose, docValuesContext, docValuesContext, explain, explain, fetchFieldsContext, fetchFieldsContext, fetchResult, fetchSourceContext, fetchSourceContext, from, from, getRelativeTimeInMillis, groupStats, hasFetchSourceContext, hasScriptFields, hasStoredFields, hasStoredFieldsContext, highlight, highlight, minimumScore, parsedPostFilter, parsedQuery, parsedQuery, preProcess, query, queryResult, scriptFields, seqNoAndPrimaryTerm, seqNoAndPrimaryTerm, size, size, sort, sort, sourceRequested, storedFieldsContext, storedFieldsContext, storedFieldsRequested, suggest, terminateAfter, timeout, trackScores, trackScores, version, versionMethods inherited from class org.elasticsearch.search.internal.FilteredSearchContext
addRescore, addSearchExt, aggregations, aliasFilter, bigArrays, bitsetFilterCache, collapse, dfsResult, fetchPhase, fieldType, getObjectMapper, getProfilers, getQueryShardContext, getSearchExt, getTask, groupStats, id, indexShard, isCancelled, lowLevelCancellation, mapperService, minimumScore, numberOfShards, parsedPostFilter, queryBoost, queryCollectors, readerContext, request, rescore, scrollContext, searchAfter, searchAfter, searcher, searchType, setTask, shardTarget, similarityService, source, suggest, terminateAfter, timeout, trackTotalHitsUpTo, trackTotalHitsUpToMethods inherited from class org.elasticsearch.search.internal.SearchContext
addReleasable, assignRescoreDocIds, close, hasOnlySuggest, rescoreDocIds, toString
-
Field Details
-
Constructor Details
-
Method Details
-
topDocs
- Throws:
java.io.IOException
-
getName
public java.lang.String getName() -
innerHits
- Overrides:
innerHitsin classFilteredSearchContext
-
setChildInnerHits
public void setChildInnerHits(java.util.Map<java.lang.String,InnerHitsContext.InnerHitSubContext> childInnerHits) -
getInnerHitQueryWeight
protected org.apache.lucene.search.Weight getInnerHitQueryWeight() throws java.io.IOException- Throws:
java.io.IOException
-
parentSearchContext
-
getRootId
The _id of the root document. Since this ID is available on the context, inner hits can avoid re-loading the root _id. -
setRootId
-
getRootLookup
A source lookup for the root document. This shared lookup allows inner hits to avoid re-loading the root _source. -
setRootLookup
-