Class CfnCustomMetricProps.Builder

java.lang.Object
software.amazon.awscdk.services.iot.CfnCustomMetricProps.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CfnCustomMetricProps>
Enclosing interface:
CfnCustomMetricProps

@Stability(Stable) public static final class CfnCustomMetricProps.Builder extends Object implements software.amazon.jsii.Builder<CfnCustomMetricProps>
A builder for CfnCustomMetricProps
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • metricType

      @Stability(Stable) public CfnCustomMetricProps.Builder metricType(String metricType)
      Parameters:
      metricType - The type of the custom metric. Types include string-list , ip-address-list , number-list , and number . This parameter is required.

      The type number only takes a single metric value as an input, but when you submit the metrics value in the DeviceMetrics report, you must pass it as an array with a single value.

      Returns:
      this
    • displayName

      @Stability(Stable) public CfnCustomMetricProps.Builder displayName(String displayName)
      Parameters:
      displayName - The friendly name in the console for the custom metric. This name doesn't have to be unique. Don't use this name as the metric identifier in the device metric report. You can update the friendly name after you define it.
      Returns:
      this
    • metricName

      @Stability(Stable) public CfnCustomMetricProps.Builder metricName(String metricName)
      Parameters:
      metricName - The name of the custom metric. This will be used in the metric report submitted from the device/thing. The name can't begin with aws: . You can’t change the name after you define it.
      Returns:
      this
    • tags

      @Stability(Stable) public CfnCustomMetricProps.Builder tags(List<? extends CfnTag> tags)
      Parameters:
      tags - Metadata that can be used to manage the custom metric.
      Returns:
      this
    • build

      @Stability(Stable) public CfnCustomMetricProps build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnCustomMetricProps>
      Returns:
      a new instance of CfnCustomMetricProps
      Throws:
      NullPointerException - if any required attribute was not provided