public final class QueryRequest
extends com.google.api.client.json.GenericJson
This is the Java data model class that specifies how to parse/serialize into the JSON that is transmitted over HTTP when working with the BigQuery API. For a detailed explanation see: https://developers.google.com/api-client-library/java/google-http-java-client/json
com.google.api.client.util.GenericData.Flags
Constructor and Description |
---|
QueryRequest() |
Modifier and Type | Method and Description |
---|---|
QueryRequest |
clone() |
DatasetReference |
getDefaultDataset()
[Optional] Specifies the default datasetId and projectId to assume for any unqualified table
names in the query.
|
java.lang.Boolean |
getDryRun()
[Optional] If set to true, BigQuery doesn't run the job.
|
java.lang.String |
getKind()
The resource type of the request.
|
java.lang.Long |
getMaxResults()
[Optional] The maximum number of rows of data to return per page of results.
|
java.lang.Boolean |
getPreserveNulls()
[Deprecated] This property is deprecated.
|
java.lang.String |
getQuery()
[Required] A query string, following the BigQuery query syntax, of the query to execute.
|
java.lang.Long |
getTimeoutMs()
[Optional] How long to wait for the query to complete, in milliseconds, before the request
times out and returns.
|
java.lang.Boolean |
getUseQueryCache()
[Optional] Whether to look for the result in the query cache.
|
boolean |
isUseQueryCache()
Convenience method that returns only
Boolean.TRUE or Boolean.FALSE . |
QueryRequest |
set(java.lang.String fieldName,
java.lang.Object value) |
QueryRequest |
setDefaultDataset(DatasetReference defaultDataset)
[Optional] Specifies the default datasetId and projectId to assume for any unqualified table
names in the query.
|
QueryRequest |
setDryRun(java.lang.Boolean dryRun)
[Optional] If set to true, BigQuery doesn't run the job.
|
QueryRequest |
setKind(java.lang.String kind)
The resource type of the request.
|
QueryRequest |
setMaxResults(java.lang.Long maxResults)
[Optional] The maximum number of rows of data to return per page of results.
|
QueryRequest |
setPreserveNulls(java.lang.Boolean preserveNulls)
[Deprecated] This property is deprecated.
|
QueryRequest |
setQuery(java.lang.String query)
[Required] A query string, following the BigQuery query syntax, of the query to execute.
|
QueryRequest |
setTimeoutMs(java.lang.Long timeoutMs)
[Optional] How long to wait for the query to complete, in milliseconds, before the request
times out and returns.
|
QueryRequest |
setUseQueryCache(java.lang.Boolean useQueryCache)
[Optional] Whether to look for the result in the query cache.
|
getFactory, setFactory, toPrettyString, toString
entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeys
public DatasetReference getDefaultDataset()
null
for nonepublic QueryRequest setDefaultDataset(DatasetReference defaultDataset)
defaultDataset
- defaultDataset or null
for nonepublic java.lang.Boolean getDryRun()
null
for nonepublic QueryRequest setDryRun(java.lang.Boolean dryRun)
dryRun
- dryRun or null
for nonepublic java.lang.String getKind()
null
for nonepublic QueryRequest setKind(java.lang.String kind)
kind
- kind or null
for nonepublic java.lang.Long getMaxResults()
null
for nonepublic QueryRequest setMaxResults(java.lang.Long maxResults)
maxResults
- maxResults or null
for nonepublic java.lang.Boolean getPreserveNulls()
null
for nonepublic QueryRequest setPreserveNulls(java.lang.Boolean preserveNulls)
preserveNulls
- preserveNulls or null
for nonepublic java.lang.String getQuery()
null
for nonepublic QueryRequest setQuery(java.lang.String query)
query
- query or null
for nonepublic java.lang.Long getTimeoutMs()
null
for nonepublic QueryRequest setTimeoutMs(java.lang.Long timeoutMs)
timeoutMs
- timeoutMs or null
for nonepublic java.lang.Boolean getUseQueryCache()
null
for nonepublic QueryRequest setUseQueryCache(java.lang.Boolean useQueryCache)
useQueryCache
- useQueryCache or null
for nonepublic boolean isUseQueryCache()
Boolean.TRUE
or Boolean.FALSE
.
Boolean properties can have four possible values:
null
, Data.NULL_BOOLEAN
, Boolean.TRUE
or Boolean.FALSE
.
This method returns Boolean.TRUE
if the default of the property is Boolean.TRUE
and it is null
or Data.NULL_BOOLEAN
.
Boolean.FALSE
is returned if the default of the property is Boolean.FALSE
and
it is null
or Data.NULL_BOOLEAN
.
[ Optional] Whether to look for the result in the query cache. The query cache is a best-effort [ cache that will be flushed whenever tables in the query are modified. The default value is true.
public QueryRequest set(java.lang.String fieldName, java.lang.Object value)
set
in class com.google.api.client.json.GenericJson
public QueryRequest clone()
clone
in class com.google.api.client.json.GenericJson