Package com.veeva.vault.sdk.api.query
Interface QueryExecutionResponse
public interface QueryExecutionResponse
Represents the result of a VQL query execution.
-
Method Summary
Modifier and TypeMethodDescriptionRetrieves theQueryFacetResponse
.Retrieves the executed query string.long
Retrieves the total number of results satisfying the query.boolean
Checks whether the response contains aQueryFacetResponse
.Streams the query results in the native query format,QueryExecutionResult
.
-
Method Details
-
getQueryString
String getQueryString()Retrieves the executed query string. If tokens are used, then the tokens in the query string are resolved.- Returns:
- the executed query string
-
getResultCount
long getResultCount()Retrieves the total number of results satisfying the query.- Returns:
- the total number of results satisfying the query
-
streamResults
Stream<QueryExecutionResult> streamResults()Streams the query results in the native query format,QueryExecutionResult
.This stream returns all results qualified by the query. There is no concept of result pages as seen in the VQL REST API.
To traverse the stream results in the classic iterator model, use the returned stream's
BaseStream.iterator()
method.- Returns:
- the query results in the native query format
-
hasFacetResponse
boolean hasFacetResponse()Checks whether the response contains aQueryFacetResponse
.- Returns:
- true if the response contains a facet response, false otherwise
-
getFacetResponse
QueryFacetResponse getFacetResponse()Retrieves theQueryFacetResponse
.- Returns:
- the QueryFacetResponse
-