Interface Metric.Builder
- All Superinterfaces:
Buildable
,CopyableBuilder<Metric.Builder,
,Metric> SdkBuilder<Metric.Builder,
,Metric> SdkPojo
- Enclosing class:
Metric
-
Method Summary
Modifier and TypeMethodDescriptiondimensions
(Collection<MetricDimension> dimensions) The dimensions for the metric.dimensions
(Consumer<MetricDimension.Builder>... dimensions) The dimensions for the metric.dimensions
(MetricDimension... dimensions) The dimensions for the metric.metricName
(String metricName) The name of the metric.The namespace of the metric.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFields
-
Method Details
-
namespace
The namespace of the metric. For more information, see the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.
- Parameters:
namespace
- The namespace of the metric. For more information, see the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
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.
-
dimensions
The dimensions for the metric. For the list of available dimensions, see the Amazon Web Services documentation available from the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.
Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.
- Parameters:
dimensions
- The dimensions for the metric. For the list of available dimensions, see the Amazon Web Services documentation available from the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
dimensions
The dimensions for the metric. For the list of available dimensions, see the Amazon Web Services documentation available from the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.
Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.
- Parameters:
dimensions
- The dimensions for the metric. For the list of available dimensions, see the Amazon Web Services documentation available from the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
dimensions
The dimensions for the metric. For the list of available dimensions, see the Amazon Web Services documentation available from the table in Amazon Web Services services that publish CloudWatch metrics in the Amazon CloudWatch User Guide.
Conditional: If you published your metric with dimensions, you must specify the same dimensions in your scaling policy.
This is a convenience method that creates an instance of theMetricDimension.Builder
avoiding the need to create one manually viaMetricDimension.builder()
.When the
Consumer
completes,SdkBuilder.build()
is called immediately and its result is passed todimensions(List<MetricDimension>)
.- Parameters:
dimensions
- a consumer that will call methods onMetricDimension.Builder
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
-