Interface QueryResponse.Builder
- All Superinterfaces:
AwsResponse.Builder
,Buildable
,CopyableBuilder<QueryResponse.Builder,
,QueryResponse> KendraResponse.Builder
,SdkBuilder<QueryResponse.Builder,
,QueryResponse> SdkPojo
,SdkResponse.Builder
- Enclosing class:
QueryResponse
-
Method Summary
Modifier and TypeMethodDescriptionfacetResults
(Collection<FacetResult> facetResults) Contains the facet results.facetResults
(Consumer<FacetResult.Builder>... facetResults) Contains the facet results.facetResults
(FacetResult... facetResults) Contains the facet results.featuredResultsItems
(Collection<FeaturedResultsItem> featuredResultsItems) The list of featured result items.featuredResultsItems
(Consumer<FeaturedResultsItem.Builder>... featuredResultsItems) The list of featured result items.featuredResultsItems
(FeaturedResultsItem... featuredResultsItems) The list of featured result items.The identifier for the search.resultItems
(Collection<QueryResultItem> resultItems) The results of the search.resultItems
(Consumer<QueryResultItem.Builder>... resultItems) The results of the search.resultItems
(QueryResultItem... resultItems) The results of the search.spellCorrectedQueries
(Collection<SpellCorrectedQuery> spellCorrectedQueries) A list of information related to suggested spell corrections for a query.spellCorrectedQueries
(Consumer<SpellCorrectedQuery.Builder>... spellCorrectedQueries) A list of information related to suggested spell corrections for a query.spellCorrectedQueries
(SpellCorrectedQuery... spellCorrectedQueries) A list of information related to suggested spell corrections for a query.totalNumberOfResults
(Integer totalNumberOfResults) The total number of items found by the search.warnings
(Collection<Warning> warnings) A list of warning codes and their messages on problems with your query.warnings
(Consumer<Warning.Builder>... warnings) A list of warning codes and their messages on problems with your query.A list of warning codes and their messages on problems with your query.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
Methods inherited from interface software.amazon.awssdk.services.kendra.model.KendraResponse.Builder
build, responseMetadata, responseMetadata
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFields
Methods inherited from interface software.amazon.awssdk.core.SdkResponse.Builder
sdkHttpResponse, sdkHttpResponse
-
Method Details
-
queryId
The identifier for the search. You also use
QueryId
to identify the search when using the SubmitFeedback API.- Parameters:
queryId
- The identifier for the search. You also useQueryId
to identify the search when using the SubmitFeedback API.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
resultItems
The results of the search.
- Parameters:
resultItems
- The results of the search.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
resultItems
The results of the search.
- Parameters:
resultItems
- The results of the search.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
resultItems
The results of the search.
This is a convenience method that creates an instance of theQueryResultItem.Builder
avoiding the need to create one manually viaQueryResultItem.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed toresultItems(List<QueryResultItem>)
.- Parameters:
resultItems
- a consumer that will call methods onQueryResultItem.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
facetResults
Contains the facet results. A
FacetResult
contains the counts for each field/attribute key that was specified in theFacets
input parameter.- Parameters:
facetResults
- Contains the facet results. AFacetResult
contains the counts for each field/attribute key that was specified in theFacets
input parameter.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
facetResults
Contains the facet results. A
FacetResult
contains the counts for each field/attribute key that was specified in theFacets
input parameter.- Parameters:
facetResults
- Contains the facet results. AFacetResult
contains the counts for each field/attribute key that was specified in theFacets
input parameter.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
facetResults
Contains the facet results. A
This is a convenience method that creates an instance of theFacetResult
contains the counts for each field/attribute key that was specified in theFacets
input parameter.FacetResult.Builder
avoiding the need to create one manually viaFacetResult.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed tofacetResults(List<FacetResult>)
.- Parameters:
facetResults
- a consumer that will call methods onFacetResult.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
totalNumberOfResults
The total number of items found by the search. However, you can only retrieve up to 100 items. For example, if the search found 192 items, you can only retrieve the first 100 of the items.
- Parameters:
totalNumberOfResults
- The total number of items found by the search. However, you can only retrieve up to 100 items. For example, if the search found 192 items, you can only retrieve the first 100 of the items.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
warnings
A list of warning codes and their messages on problems with your query.
Amazon Kendra currently only supports one type of warning, which is a warning on invalid syntax used in the query. For examples of invalid query syntax, see Searching with advanced query syntax.
- Parameters:
warnings
- A list of warning codes and their messages on problems with your query.Amazon Kendra currently only supports one type of warning, which is a warning on invalid syntax used in the query. For examples of invalid query syntax, see Searching with advanced query syntax.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
warnings
A list of warning codes and their messages on problems with your query.
Amazon Kendra currently only supports one type of warning, which is a warning on invalid syntax used in the query. For examples of invalid query syntax, see Searching with advanced query syntax.
- Parameters:
warnings
- A list of warning codes and their messages on problems with your query.Amazon Kendra currently only supports one type of warning, which is a warning on invalid syntax used in the query. For examples of invalid query syntax, see Searching with advanced query syntax.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
warnings
A list of warning codes and their messages on problems with your query.
Amazon Kendra currently only supports one type of warning, which is a warning on invalid syntax used in the query. For examples of invalid query syntax, see Searching with advanced query syntax.
This is a convenience method that creates an instance of theWarning.Builder
avoiding the need to create one manually viaWarning.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed towarnings(List<Warning>)
.- Parameters:
warnings
- a consumer that will call methods onWarning.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
spellCorrectedQueries
A list of information related to suggested spell corrections for a query.
- Parameters:
spellCorrectedQueries
- A list of information related to suggested spell corrections for a query.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
spellCorrectedQueries
A list of information related to suggested spell corrections for a query.
- Parameters:
spellCorrectedQueries
- A list of information related to suggested spell corrections for a query.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
spellCorrectedQueries
QueryResponse.Builder spellCorrectedQueries(Consumer<SpellCorrectedQuery.Builder>... spellCorrectedQueries) A list of information related to suggested spell corrections for a query.
This is a convenience method that creates an instance of theSpellCorrectedQuery.Builder
avoiding the need to create one manually viaSpellCorrectedQuery.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed tospellCorrectedQueries(List<SpellCorrectedQuery>)
.- Parameters:
spellCorrectedQueries
- a consumer that will call methods onSpellCorrectedQuery.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-
featuredResultsItems
The list of featured result items. Featured results are displayed at the top of the search results page, placed above all other results for certain queries. If there's an exact match of a query, then certain documents are featured in the search results.
- Parameters:
featuredResultsItems
- The list of featured result items. Featured results are displayed at the top of the search results page, placed above all other results for certain queries. If there's an exact match of a query, then certain documents are featured in the search results.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
featuredResultsItems
The list of featured result items. Featured results are displayed at the top of the search results page, placed above all other results for certain queries. If there's an exact match of a query, then certain documents are featured in the search results.
- Parameters:
featuredResultsItems
- The list of featured result items. Featured results are displayed at the top of the search results page, placed above all other results for certain queries. If there's an exact match of a query, then certain documents are featured in the search results.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
featuredResultsItems
QueryResponse.Builder featuredResultsItems(Consumer<FeaturedResultsItem.Builder>... featuredResultsItems) The list of featured result items. Featured results are displayed at the top of the search results page, placed above all other results for certain queries. If there's an exact match of a query, then certain documents are featured in the search results.
This is a convenience method that creates an instance of theFeaturedResultsItem.Builder
avoiding the need to create one manually viaFeaturedResultsItem.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed tofeaturedResultsItems(List<FeaturedResultsItem>)
.- Parameters:
featuredResultsItems
- a consumer that will call methods onFeaturedResultsItem.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-