Package com.influxdb.client.domain
Class InfluxQLQuery
java.lang.Object
com.influxdb.client.domain.InfluxQLQuery
A InfluxQL query.
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
The possible values to be used in the headerAccept
, when making queries.static enum
The precision used for the timestamps returned by InfluxQL queries. -
Constructor Summary
ConstructorDescriptionInfluxQLQuery
(String command, String database) InfluxQLQuery
(String command, String database, InfluxQLQuery.AcceptHeader acceptHeader) -
Method Summary
Modifier and TypeMethodDescriptionsetAcceptHeader
(InfluxQLQuery.AcceptHeader acceptHeader) setPrecision
(InfluxQLQuery.InfluxQLPrecision precision) setRetentionPolicy
(String retentionPolicy)
-
Constructor Details
-
InfluxQLQuery
- Parameters:
command
- the InfluxQL command to executedatabase
- the database to run this query against
-
InfluxQLQuery
public InfluxQLQuery(@Nonnull String command, @Nonnull String database, @Nonnull InfluxQLQuery.AcceptHeader acceptHeader) - Parameters:
command
- the InfluxQL command to executedatabase
- the database to run this query againstacceptHeader
- theAccept
header to use in the request
-
-
Method Details
-
getCommand
- Returns:
- the InfluxQL command to execute
-
getDatabase
- Returns:
- the database to run this query against
-
getRetentionPolicy
- Returns:
- the retention policy to use
-
setRetentionPolicy
- Parameters:
retentionPolicy
- the retention policy to use- Returns:
- this
-
getPrecision
- Returns:
- The precision used for the timestamps returned by the query
-
setPrecision
- Parameters:
precision
- The precision used for the timestamps returned by the query- Returns:
- this
-
getAcceptHeader
- Returns:
- the current AcceptHeader used when making queries.
-
setAcceptHeader
- Parameters:
acceptHeader
- the AcceptHeader to be used when making queries.- Returns:
- this
-
getAcceptHeaderVal
- Returns:
- the string value of the AcceptHeader used when making queries.
-