Class QueryResponse
java.lang.Object
com.ibm.cloud.sdk.core.service.model.GenericModel
com.ibm.watson.discovery.v2.model.QueryResponse
- All Implemented Interfaces:
com.ibm.cloud.sdk.core.service.model.ObjectModel
public class QueryResponse
extends com.ibm.cloud.sdk.core.service.model.GenericModel
A response containing the documents and aggregations for the query.
-
Constructor Summary
Constructors Constructor Description QueryResponse()
-
Method Summary
Modifier and Type Method Description List<QueryAggregation>
getAggregations()
Gets the aggregations.Long
getMatchingResults()
Gets the matchingResults.List<QueryResponsePassage>
getPassages()
Gets the passages.List<QueryResult>
getResults()
Gets the results.RetrievalDetails
getRetrievalDetails()
Gets the retrievalDetails.String
getSuggestedQuery()
Gets the suggestedQuery.List<QuerySuggestedRefinement>
getSuggestedRefinements()
Gets the suggestedRefinements.List<QueryTableResult>
getTableResults()
Gets the tableResults.Methods inherited from class com.ibm.cloud.sdk.core.service.model.GenericModel
equals, hashCode, toString
-
Constructor Details
-
QueryResponse
public QueryResponse()
-
-
Method Details
-
getMatchingResults
Gets the matchingResults.The number of matching results for the query.
- Returns:
- the matchingResults
-
getResults
Gets the results.Array of document results for the query.
- Returns:
- the results
-
getAggregations
Gets the aggregations.Array of aggregations for the query.
- Returns:
- the aggregations
-
getRetrievalDetails
Gets the retrievalDetails.An object contain retrieval type information.
- Returns:
- the retrievalDetails
-
getSuggestedQuery
Gets the suggestedQuery.Suggested correction to the submitted **natural_language_query** value.
- Returns:
- the suggestedQuery
-
getSuggestedRefinements
Gets the suggestedRefinements.Array of suggested refinements.
- Returns:
- the suggestedRefinements
-
getTableResults
Gets the tableResults.Array of table results.
- Returns:
- the tableResults
-
getPassages
Gets the passages.Passages returned by Discovery.
- Returns:
- the passages
-