Class MetricDatum

    • Constructor Detail

      • MetricDatum

        public MetricDatum()
    • Method Detail

      • setMetricName

        public void setMetricName​(String metricName)

        The name of the metric.

        Parameters:
        metricName - The name of the metric.
      • getMetricName

        public String getMetricName()

        The name of the metric.

        Returns:
        The name of the metric.
      • withMetricName

        public MetricDatum withMetricName​(String metricName)

        The name of the metric.

        Parameters:
        metricName - The name of the metric.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • getDimensions

        public List<Dimension> getDimensions()

        A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).

        Returns:
        A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).
      • setDimensions

        public void setDimensions​(Collection<Dimension> dimensions)

        A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).

        Parameters:
        dimensions - A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).
      • withDimensions

        public MetricDatum withDimensions​(Dimension... dimensions)

        A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).

        NOTE: This method appends the values to the existing list (if any). Use setDimensions(java.util.Collection) or withDimensions(java.util.Collection) if you want to override the existing values.

        Parameters:
        dimensions - A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • withDimensions

        public MetricDatum withDimensions​(Collection<Dimension> dimensions)

        A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).

        Parameters:
        dimensions - A list of dimensions associated with the metric. Note, when using the Dimensions value in a query, you need to append .member.N to it (e.g., Dimensions.member.N).
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setTimestamp

        public void setTimestamp​(Date timestamp)

        The time stamp used for the metric in ISO 8601 Universal Coordinated Time (UTC) format. If not specified, the default value is set to the time the metric data was received.

        Parameters:
        timestamp - The time stamp used for the metric in ISO 8601 Universal Coordinated Time (UTC) format. If not specified, the default value is set to the time the metric data was received.
      • getTimestamp

        public Date getTimestamp()

        The time stamp used for the metric in ISO 8601 Universal Coordinated Time (UTC) format. If not specified, the default value is set to the time the metric data was received.

        Returns:
        The time stamp used for the metric in ISO 8601 Universal Coordinated Time (UTC) format. If not specified, the default value is set to the time the metric data was received.
      • withTimestamp

        public MetricDatum withTimestamp​(Date timestamp)

        The time stamp used for the metric in ISO 8601 Universal Coordinated Time (UTC) format. If not specified, the default value is set to the time the metric data was received.

        Parameters:
        timestamp - The time stamp used for the metric in ISO 8601 Universal Coordinated Time (UTC) format. If not specified, the default value is set to the time the metric data was received.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setValue

        public void setValue​(Double value)

        The value for the metric.

        Although the Value parameter accepts numbers of type Double, Amazon CloudWatch rejects values that are either too small or too large. Values must be in the range of 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2). In addition, special values (e.g., NaN, +Infinity, -Infinity) are not supported.
        Parameters:
        value - The value for the metric.

        Although the Value parameter accepts numbers of type Double, Amazon CloudWatch rejects values that are either too small or too large. Values must be in the range of 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2). In addition, special values (e.g., NaN, +Infinity, -Infinity) are not supported.
      • getValue

        public Double getValue()

        The value for the metric.

        Although the Value parameter accepts numbers of type Double, Amazon CloudWatch rejects values that are either too small or too large. Values must be in the range of 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2). In addition, special values (e.g., NaN, +Infinity, -Infinity) are not supported.
        Returns:
        The value for the metric.

        Although the Value parameter accepts numbers of type Double, Amazon CloudWatch rejects values that are either too small or too large. Values must be in the range of 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2). In addition, special values (e.g., NaN, +Infinity, -Infinity) are not supported.
      • withValue

        public MetricDatum withValue​(Double value)

        The value for the metric.

        Although the Value parameter accepts numbers of type Double, Amazon CloudWatch rejects values that are either too small or too large. Values must be in the range of 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2). In addition, special values (e.g., NaN, +Infinity, -Infinity) are not supported.
        Parameters:
        value - The value for the metric.

        Although the Value parameter accepts numbers of type Double, Amazon CloudWatch rejects values that are either too small or too large. Values must be in the range of 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2). In addition, special values (e.g., NaN, +Infinity, -Infinity) are not supported.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setStatisticValues

        public void setStatisticValues​(StatisticSet statisticValues)

        A set of statistical values describing the metric.

        Parameters:
        statisticValues - A set of statistical values describing the metric.
      • getStatisticValues

        public StatisticSet getStatisticValues()

        A set of statistical values describing the metric.

        Returns:
        A set of statistical values describing the metric.
      • withStatisticValues

        public MetricDatum withStatisticValues​(StatisticSet statisticValues)

        A set of statistical values describing the metric.

        Parameters:
        statisticValues - A set of statistical values describing the metric.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setUnit

        public void setUnit​(String unit)

        The unit of the metric.

        Parameters:
        unit - The unit of the metric.
        See Also:
        StandardUnit
      • getUnit

        public String getUnit()

        The unit of the metric.

        Returns:
        The unit of the metric.
        See Also:
        StandardUnit
      • withUnit

        public MetricDatum withUnit​(String unit)

        The unit of the metric.

        Parameters:
        unit - The unit of the metric.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        StandardUnit
      • setUnit

        public void setUnit​(StandardUnit unit)

        The unit of the metric.

        Parameters:
        unit - The unit of the metric.
        See Also:
        StandardUnit
      • withUnit

        public MetricDatum withUnit​(StandardUnit unit)

        The unit of the metric.

        Parameters:
        unit - The unit of the metric.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        StandardUnit
      • toString

        public String toString()
        Returns a string representation of this object; useful for testing and debugging.
        Overrides:
        toString in class Object
        Returns:
        A string representation of this object.
        See Also:
        Object.toString()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object