Class Scorecard (2.23.0)

public final class Scorecard extends GeneratedMessageV3 implements ScorecardOrBuilder

A widget showing the latest value of a metric, and how this value relates to one or more thresholds.

Protobuf type google.monitoring.dashboard.v1.Scorecard

Implements

ScorecardOrBuilder

Static Fields

GAUGE_VIEW_FIELD_NUMBER

public static final int GAUGE_VIEW_FIELD_NUMBER
Field Value
TypeDescription
int

SPARK_CHART_VIEW_FIELD_NUMBER

public static final int SPARK_CHART_VIEW_FIELD_NUMBER
Field Value
TypeDescription
int

THRESHOLDS_FIELD_NUMBER

public static final int THRESHOLDS_FIELD_NUMBER
Field Value
TypeDescription
int

TIME_SERIES_QUERY_FIELD_NUMBER

public static final int TIME_SERIES_QUERY_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static Scorecard getDefaultInstance()
Returns
TypeDescription
Scorecard

getDescriptor()

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

newBuilder()

public static Scorecard.Builder newBuilder()
Returns
TypeDescription
Scorecard.Builder

newBuilder(Scorecard prototype)

public static Scorecard.Builder newBuilder(Scorecard prototype)
Parameter
NameDescription
prototypeScorecard
Returns
TypeDescription
Scorecard.Builder

parseDelimitedFrom(InputStream input)

public static Scorecard parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Scorecard parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static Scorecard parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static Scorecard parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static Scorecard parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static Scorecard parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static Scorecard parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static Scorecard parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static Scorecard parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static Scorecard parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static Scorecard parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static Scorecard parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
Scorecard
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<Scorecard> parser()
Returns
TypeDescription
Parser<Scorecard>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getDataViewCase()

public Scorecard.DataViewCase getDataViewCase()
Returns
TypeDescription
Scorecard.DataViewCase

getDefaultInstanceForType()

public Scorecard getDefaultInstanceForType()
Returns
TypeDescription
Scorecard

getGaugeView()

public Scorecard.GaugeView getGaugeView()

Will cause the scorecard to show a gauge chart.

.google.monitoring.dashboard.v1.Scorecard.GaugeView gauge_view = 4;

Returns
TypeDescription
Scorecard.GaugeView

The gaugeView.

getGaugeViewOrBuilder()

public Scorecard.GaugeViewOrBuilder getGaugeViewOrBuilder()

Will cause the scorecard to show a gauge chart.

.google.monitoring.dashboard.v1.Scorecard.GaugeView gauge_view = 4;

Returns
TypeDescription
Scorecard.GaugeViewOrBuilder

getParserForType()

public Parser<Scorecard> getParserForType()
Returns
TypeDescription
Parser<Scorecard>
Overrides

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getSparkChartView()

public Scorecard.SparkChartView getSparkChartView()

Will cause the scorecard to show a spark chart.

.google.monitoring.dashboard.v1.Scorecard.SparkChartView spark_chart_view = 5;

Returns
TypeDescription
Scorecard.SparkChartView

The sparkChartView.

getSparkChartViewOrBuilder()

public Scorecard.SparkChartViewOrBuilder getSparkChartViewOrBuilder()

Will cause the scorecard to show a spark chart.

.google.monitoring.dashboard.v1.Scorecard.SparkChartView spark_chart_view = 5;

Returns
TypeDescription
Scorecard.SparkChartViewOrBuilder

getThresholds(int index)

public Threshold getThresholds(int index)

The thresholds used to determine the state of the scorecard given the time series' current value. For an actual value x, the scorecard is in a danger state if x is less than or equal to a danger threshold that triggers below, or greater than or equal to a danger threshold that triggers above. Similarly, if x is above/below a warning threshold that triggers above/below, then the scorecard is in a warning state - unless x also puts it in a danger state. (Danger trumps warning.)

As an example, consider a scorecard with the following four thresholds:

<code><code> { value: 90, category: 'DANGER', trigger: 'ABOVE', }, { value: 70, category: 'WARNING', trigger: 'ABOVE', }, { value: 10, category: 'DANGER', trigger: 'BELOW', }, { value: 20, category: 'WARNING', trigger: 'BELOW', } </code></code>

Then: values less than or equal to 10 would put the scorecard in a DANGER state, values greater than 10 but less than or equal to 20 a WARNING state, values strictly between 20 and 70 an OK state, values greater than or equal to 70 but less than 90 a WARNING state, and values greater than or equal to 90 a DANGER state.

repeated .google.monitoring.dashboard.v1.Threshold thresholds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
Threshold

getThresholdsCount()

public int getThresholdsCount()

The thresholds used to determine the state of the scorecard given the time series' current value. For an actual value x, the scorecard is in a danger state if x is less than or equal to a danger threshold that triggers below, or greater than or equal to a danger threshold that triggers above. Similarly, if x is above/below a warning threshold that triggers above/below, then the scorecard is in a warning state - unless x also puts it in a danger state. (Danger trumps warning.)

As an example, consider a scorecard with the following four thresholds:

<code><code> { value: 90, category: 'DANGER', trigger: 'ABOVE', }, { value: 70, category: 'WARNING', trigger: 'ABOVE', }, { value: 10, category: 'DANGER', trigger: 'BELOW', }, { value: 20, category: 'WARNING', trigger: 'BELOW', } </code></code>

Then: values less than or equal to 10 would put the scorecard in a DANGER state, values greater than 10 but less than or equal to 20 a WARNING state, values strictly between 20 and 70 an OK state, values greater than or equal to 70 but less than 90 a WARNING state, and values greater than or equal to 90 a DANGER state.

repeated .google.monitoring.dashboard.v1.Threshold thresholds = 6;

Returns
TypeDescription
int

getThresholdsList()

public List<Threshold> getThresholdsList()

The thresholds used to determine the state of the scorecard given the time series' current value. For an actual value x, the scorecard is in a danger state if x is less than or equal to a danger threshold that triggers below, or greater than or equal to a danger threshold that triggers above. Similarly, if x is above/below a warning threshold that triggers above/below, then the scorecard is in a warning state - unless x also puts it in a danger state. (Danger trumps warning.)

As an example, consider a scorecard with the following four thresholds:

<code><code> { value: 90, category: 'DANGER', trigger: 'ABOVE', }, { value: 70, category: 'WARNING', trigger: 'ABOVE', }, { value: 10, category: 'DANGER', trigger: 'BELOW', }, { value: 20, category: 'WARNING', trigger: 'BELOW', } </code></code>

Then: values less than or equal to 10 would put the scorecard in a DANGER state, values greater than 10 but less than or equal to 20 a WARNING state, values strictly between 20 and 70 an OK state, values greater than or equal to 70 but less than 90 a WARNING state, and values greater than or equal to 90 a DANGER state.

repeated .google.monitoring.dashboard.v1.Threshold thresholds = 6;

Returns
TypeDescription
List<Threshold>

getThresholdsOrBuilder(int index)

public ThresholdOrBuilder getThresholdsOrBuilder(int index)

The thresholds used to determine the state of the scorecard given the time series' current value. For an actual value x, the scorecard is in a danger state if x is less than or equal to a danger threshold that triggers below, or greater than or equal to a danger threshold that triggers above. Similarly, if x is above/below a warning threshold that triggers above/below, then the scorecard is in a warning state - unless x also puts it in a danger state. (Danger trumps warning.)

As an example, consider a scorecard with the following four thresholds:

<code><code> { value: 90, category: 'DANGER', trigger: 'ABOVE', }, { value: 70, category: 'WARNING', trigger: 'ABOVE', }, { value: 10, category: 'DANGER', trigger: 'BELOW', }, { value: 20, category: 'WARNING', trigger: 'BELOW', } </code></code>

Then: values less than or equal to 10 would put the scorecard in a DANGER state, values greater than 10 but less than or equal to 20 a WARNING state, values strictly between 20 and 70 an OK state, values greater than or equal to 70 but less than 90 a WARNING state, and values greater than or equal to 90 a DANGER state.

repeated .google.monitoring.dashboard.v1.Threshold thresholds = 6;

Parameter
NameDescription
indexint
Returns
TypeDescription
ThresholdOrBuilder

getThresholdsOrBuilderList()

public List<? extends ThresholdOrBuilder> getThresholdsOrBuilderList()

The thresholds used to determine the state of the scorecard given the time series' current value. For an actual value x, the scorecard is in a danger state if x is less than or equal to a danger threshold that triggers below, or greater than or equal to a danger threshold that triggers above. Similarly, if x is above/below a warning threshold that triggers above/below, then the scorecard is in a warning state - unless x also puts it in a danger state. (Danger trumps warning.)

As an example, consider a scorecard with the following four thresholds:

<code><code> { value: 90, category: 'DANGER', trigger: 'ABOVE', }, { value: 70, category: 'WARNING', trigger: 'ABOVE', }, { value: 10, category: 'DANGER', trigger: 'BELOW', }, { value: 20, category: 'WARNING', trigger: 'BELOW', } </code></code>

Then: values less than or equal to 10 would put the scorecard in a DANGER state, values greater than 10 but less than or equal to 20 a WARNING state, values strictly between 20 and 70 an OK state, values greater than or equal to 70 but less than 90 a WARNING state, and values greater than or equal to 90 a DANGER state.

repeated .google.monitoring.dashboard.v1.Threshold thresholds = 6;

Returns
TypeDescription
List<? extends com.google.monitoring.dashboard.v1.ThresholdOrBuilder>

getTimeSeriesQuery()

public TimeSeriesQuery getTimeSeriesQuery()

Required. Fields for querying time series data from the Stackdriver metrics API.

.google.monitoring.dashboard.v1.TimeSeriesQuery time_series_query = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TimeSeriesQuery

The timeSeriesQuery.

getTimeSeriesQueryOrBuilder()

public TimeSeriesQueryOrBuilder getTimeSeriesQueryOrBuilder()

Required. Fields for querying time series data from the Stackdriver metrics API.

.google.monitoring.dashboard.v1.TimeSeriesQuery time_series_query = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
TimeSeriesQueryOrBuilder

hasGaugeView()

public boolean hasGaugeView()

Will cause the scorecard to show a gauge chart.

.google.monitoring.dashboard.v1.Scorecard.GaugeView gauge_view = 4;

Returns
TypeDescription
boolean

Whether the gaugeView field is set.

hasSparkChartView()

public boolean hasSparkChartView()

Will cause the scorecard to show a spark chart.

.google.monitoring.dashboard.v1.Scorecard.SparkChartView spark_chart_view = 5;

Returns
TypeDescription
boolean

Whether the sparkChartView field is set.

hasTimeSeriesQuery()

public boolean hasTimeSeriesQuery()

Required. Fields for querying time series data from the Stackdriver metrics API.

.google.monitoring.dashboard.v1.TimeSeriesQuery time_series_query = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
TypeDescription
boolean

Whether the timeSeriesQuery field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public Scorecard.Builder newBuilderForType()
Returns
TypeDescription
Scorecard.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected Scorecard.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
Scorecard.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public Scorecard.Builder toBuilder()
Returns
TypeDescription
Scorecard.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException