Class TimeSeriesQuery.Builder (2.13.0)

public static final class TimeSeriesQuery.Builder extends GeneratedMessageV3.Builder<TimeSeriesQuery.Builder> implements TimeSeriesQueryOrBuilder

TimeSeriesQuery collects the set of supported methods for querying time series data from the Stackdriver metrics API.

Protobuf type google.monitoring.dashboard.v1.TimeSeriesQuery

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public TimeSeriesQuery.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

build()

public TimeSeriesQuery build()
Returns
TypeDescription
TimeSeriesQuery

buildPartial()

public TimeSeriesQuery buildPartial()
Returns
TypeDescription
TimeSeriesQuery

clear()

public TimeSeriesQuery.Builder clear()
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public TimeSeriesQuery.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public TimeSeriesQuery.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

clearPrometheusQuery()

public TimeSeriesQuery.Builder clearPrometheusQuery()

A query used to fetch time series with PromQL.

string prometheus_query = 6;

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

clearSource()

public TimeSeriesQuery.Builder clearSource()
Returns
TypeDescription
TimeSeriesQuery.Builder

clearTimeSeriesFilter()

public TimeSeriesQuery.Builder clearTimeSeriesFilter()

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Returns
TypeDescription
TimeSeriesQuery.Builder

clearTimeSeriesFilterRatio()

public TimeSeriesQuery.Builder clearTimeSeriesFilterRatio()

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Returns
TypeDescription
TimeSeriesQuery.Builder

clearTimeSeriesQueryLanguage()

public TimeSeriesQuery.Builder clearTimeSeriesQueryLanguage()

A query used to fetch time series with MQL.

string time_series_query_language = 3;

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

clearUnitOverride()

public TimeSeriesQuery.Builder clearUnitOverride()

The unit of data contained in fetched time series. If non-empty, this unit will override any unit that accompanies fetched data. The format is the same as the unit field in MetricDescriptor.

string unit_override = 5;

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

clone()

public TimeSeriesQuery.Builder clone()
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

getDefaultInstanceForType()

public TimeSeriesQuery getDefaultInstanceForType()
Returns
TypeDescription
TimeSeriesQuery

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getPrometheusQuery()

public String getPrometheusQuery()

A query used to fetch time series with PromQL.

string prometheus_query = 6;

Returns
TypeDescription
String

The prometheusQuery.

getPrometheusQueryBytes()

public ByteString getPrometheusQueryBytes()

A query used to fetch time series with PromQL.

string prometheus_query = 6;

Returns
TypeDescription
ByteString

The bytes for prometheusQuery.

getSourceCase()

public TimeSeriesQuery.SourceCase getSourceCase()
Returns
TypeDescription
TimeSeriesQuery.SourceCase

getTimeSeriesFilter()

public TimeSeriesFilter getTimeSeriesFilter()

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Returns
TypeDescription
TimeSeriesFilter

The timeSeriesFilter.

getTimeSeriesFilterBuilder()

public TimeSeriesFilter.Builder getTimeSeriesFilterBuilder()

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Returns
TypeDescription
TimeSeriesFilter.Builder

getTimeSeriesFilterOrBuilder()

public TimeSeriesFilterOrBuilder getTimeSeriesFilterOrBuilder()

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Returns
TypeDescription
TimeSeriesFilterOrBuilder

getTimeSeriesFilterRatio()

public TimeSeriesFilterRatio getTimeSeriesFilterRatio()

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Returns
TypeDescription
TimeSeriesFilterRatio

The timeSeriesFilterRatio.

getTimeSeriesFilterRatioBuilder()

public TimeSeriesFilterRatio.Builder getTimeSeriesFilterRatioBuilder()

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Returns
TypeDescription
TimeSeriesFilterRatio.Builder

getTimeSeriesFilterRatioOrBuilder()

public TimeSeriesFilterRatioOrBuilder getTimeSeriesFilterRatioOrBuilder()

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Returns
TypeDescription
TimeSeriesFilterRatioOrBuilder

getTimeSeriesQueryLanguage()

public String getTimeSeriesQueryLanguage()

A query used to fetch time series with MQL.

string time_series_query_language = 3;

Returns
TypeDescription
String

The timeSeriesQueryLanguage.

getTimeSeriesQueryLanguageBytes()

public ByteString getTimeSeriesQueryLanguageBytes()

A query used to fetch time series with MQL.

string time_series_query_language = 3;

Returns
TypeDescription
ByteString

The bytes for timeSeriesQueryLanguage.

getUnitOverride()

public String getUnitOverride()

The unit of data contained in fetched time series. If non-empty, this unit will override any unit that accompanies fetched data. The format is the same as the unit field in MetricDescriptor.

string unit_override = 5;

Returns
TypeDescription
String

The unitOverride.

getUnitOverrideBytes()

public ByteString getUnitOverrideBytes()

The unit of data contained in fetched time series. If non-empty, this unit will override any unit that accompanies fetched data. The format is the same as the unit field in MetricDescriptor.

string unit_override = 5;

Returns
TypeDescription
ByteString

The bytes for unitOverride.

hasPrometheusQuery()

public boolean hasPrometheusQuery()

A query used to fetch time series with PromQL.

string prometheus_query = 6;

Returns
TypeDescription
boolean

Whether the prometheusQuery field is set.

hasTimeSeriesFilter()

public boolean hasTimeSeriesFilter()

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Returns
TypeDescription
boolean

Whether the timeSeriesFilter field is set.

hasTimeSeriesFilterRatio()

public boolean hasTimeSeriesFilterRatio()

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Returns
TypeDescription
boolean

Whether the timeSeriesFilterRatio field is set.

hasTimeSeriesQueryLanguage()

public boolean hasTimeSeriesQueryLanguage()

A query used to fetch time series with MQL.

string time_series_query_language = 3;

Returns
TypeDescription
boolean

Whether the timeSeriesQueryLanguage field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(TimeSeriesQuery other)

public TimeSeriesQuery.Builder mergeFrom(TimeSeriesQuery other)
Parameter
NameDescription
otherTimeSeriesQuery
Returns
TypeDescription
TimeSeriesQuery.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public TimeSeriesQuery.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public TimeSeriesQuery.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

mergeTimeSeriesFilter(TimeSeriesFilter value)

public TimeSeriesQuery.Builder mergeTimeSeriesFilter(TimeSeriesFilter value)

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Parameter
NameDescription
valueTimeSeriesFilter
Returns
TypeDescription
TimeSeriesQuery.Builder

mergeTimeSeriesFilterRatio(TimeSeriesFilterRatio value)

public TimeSeriesQuery.Builder mergeTimeSeriesFilterRatio(TimeSeriesFilterRatio value)

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Parameter
NameDescription
valueTimeSeriesFilterRatio
Returns
TypeDescription
TimeSeriesQuery.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final TimeSeriesQuery.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public TimeSeriesQuery.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

setPrometheusQuery(String value)

public TimeSeriesQuery.Builder setPrometheusQuery(String value)

A query used to fetch time series with PromQL.

string prometheus_query = 6;

Parameter
NameDescription
valueString

The prometheusQuery to set.

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

setPrometheusQueryBytes(ByteString value)

public TimeSeriesQuery.Builder setPrometheusQueryBytes(ByteString value)

A query used to fetch time series with PromQL.

string prometheus_query = 6;

Parameter
NameDescription
valueByteString

The bytes for prometheusQuery to set.

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public TimeSeriesQuery.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides

setTimeSeriesFilter(TimeSeriesFilter value)

public TimeSeriesQuery.Builder setTimeSeriesFilter(TimeSeriesFilter value)

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Parameter
NameDescription
valueTimeSeriesFilter
Returns
TypeDescription
TimeSeriesQuery.Builder

setTimeSeriesFilter(TimeSeriesFilter.Builder builderForValue)

public TimeSeriesQuery.Builder setTimeSeriesFilter(TimeSeriesFilter.Builder builderForValue)

Filter parameters to fetch time series.

.google.monitoring.dashboard.v1.TimeSeriesFilter time_series_filter = 1;

Parameter
NameDescription
builderForValueTimeSeriesFilter.Builder
Returns
TypeDescription
TimeSeriesQuery.Builder

setTimeSeriesFilterRatio(TimeSeriesFilterRatio value)

public TimeSeriesQuery.Builder setTimeSeriesFilterRatio(TimeSeriesFilterRatio value)

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Parameter
NameDescription
valueTimeSeriesFilterRatio
Returns
TypeDescription
TimeSeriesQuery.Builder

setTimeSeriesFilterRatio(TimeSeriesFilterRatio.Builder builderForValue)

public TimeSeriesQuery.Builder setTimeSeriesFilterRatio(TimeSeriesFilterRatio.Builder builderForValue)

Parameters to fetch a ratio between two time series filters.

.google.monitoring.dashboard.v1.TimeSeriesFilterRatio time_series_filter_ratio = 2;

Parameter
NameDescription
builderForValueTimeSeriesFilterRatio.Builder
Returns
TypeDescription
TimeSeriesQuery.Builder

setTimeSeriesQueryLanguage(String value)

public TimeSeriesQuery.Builder setTimeSeriesQueryLanguage(String value)

A query used to fetch time series with MQL.

string time_series_query_language = 3;

Parameter
NameDescription
valueString

The timeSeriesQueryLanguage to set.

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

setTimeSeriesQueryLanguageBytes(ByteString value)

public TimeSeriesQuery.Builder setTimeSeriesQueryLanguageBytes(ByteString value)

A query used to fetch time series with MQL.

string time_series_query_language = 3;

Parameter
NameDescription
valueByteString

The bytes for timeSeriesQueryLanguage to set.

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

setUnitOverride(String value)

public TimeSeriesQuery.Builder setUnitOverride(String value)

The unit of data contained in fetched time series. If non-empty, this unit will override any unit that accompanies fetched data. The format is the same as the unit field in MetricDescriptor.

string unit_override = 5;

Parameter
NameDescription
valueString

The unitOverride to set.

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

setUnitOverrideBytes(ByteString value)

public TimeSeriesQuery.Builder setUnitOverrideBytes(ByteString value)

The unit of data contained in fetched time series. If non-empty, this unit will override any unit that accompanies fetched data. The format is the same as the unit field in MetricDescriptor.

string unit_override = 5;

Parameter
NameDescription
valueByteString

The bytes for unitOverride to set.

Returns
TypeDescription
TimeSeriesQuery.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final TimeSeriesQuery.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
TimeSeriesQuery.Builder
Overrides