Class CompositeAlarm
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.Resource
software.amazon.awscdk.services.cloudwatch.AlarmBase
software.amazon.awscdk.services.cloudwatch.CompositeAlarm
- All Implemented Interfaces:
IResource
,IAlarm
,IAlarmRule
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.104.0 (build e79254c)",
date="2024-12-17T21:37:27.841Z")
@Stability(Stable)
public class CompositeAlarm
extends AlarmBase
A Composite Alarm based on Alarm Rule.
Example:
Alarm alarm1; Alarm alarm2; Alarm alarm3; Alarm alarm4; IAlarmRule alarmRule = AlarmRule.anyOf(AlarmRule.allOf(AlarmRule.anyOf(alarm1, AlarmRule.fromAlarm(alarm2, AlarmState.OK), alarm3), AlarmRule.not(AlarmRule.fromAlarm(alarm4, AlarmState.INSUFFICIENT_DATA))), AlarmRule.fromBoolean(false)); CompositeAlarm.Builder.create(this, "MyAwesomeCompositeAlarm") .alarmRule(alarmRule) .build();
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.services.cloudwatch.IAlarm
IAlarm.Jsii$Default
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.IResource
IResource.Jsii$Default
-
Constructor Summary
ModifierConstructorDescriptionprotected
CompositeAlarm
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CompositeAlarm
(software.amazon.jsii.JsiiObjectRef objRef) CompositeAlarm
(software.constructs.Construct scope, String id, CompositeAlarmProps props) -
Method Summary
Modifier and TypeMethodDescriptionstatic IAlarm
fromCompositeAlarmArn
(software.constructs.Construct scope, String id, String compositeAlarmArn) Import an existing CloudWatch composite alarm provided an ARN.static IAlarm
fromCompositeAlarmName
(software.constructs.Construct scope, String id, String compositeAlarmName) Import an existing CloudWatch composite alarm provided an Name.ARN of this alarm.Name of this alarm.Methods inherited from class software.amazon.awscdk.services.cloudwatch.AlarmBase
addAlarmAction, addInsufficientDataAction, addOkAction, getAlarmActionArns, getInsufficientDataActionArns, getOkActionArns, renderAlarmRule, setAlarmActionArns, setInsufficientDataActionArns, setOkActionArns
Methods inherited from class software.amazon.awscdk.Resource
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResource
Methods inherited from class software.constructs.Construct
getNode, isConstruct, toString
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.constructs.IConstruct
getNode
Methods inherited from interface software.amazon.awscdk.IResource
applyRemovalPolicy, getEnv, getStack
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
CompositeAlarm
protected CompositeAlarm(software.amazon.jsii.JsiiObjectRef objRef) -
CompositeAlarm
protected CompositeAlarm(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CompositeAlarm
@Stability(Stable) public CompositeAlarm(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CompositeAlarmProps props) - Parameters:
scope
- This parameter is required.id
- This parameter is required.props
- This parameter is required.
-
-
Method Details
-
fromCompositeAlarmArn
@Stability(Stable) @NotNull public static IAlarm fromCompositeAlarmArn(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String compositeAlarmArn) Import an existing CloudWatch composite alarm provided an ARN.- Parameters:
scope
- The parent creating construct (usuallythis
). This parameter is required.id
- The construct's name. This parameter is required.compositeAlarmArn
- Composite Alarm ARN (i.e. arn:aws:cloudwatch::invalid input: '<'account-id>:alarm:CompositeAlarmName). This parameter is required.
-
fromCompositeAlarmName
@Stability(Stable) @NotNull public static IAlarm fromCompositeAlarmName(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String compositeAlarmName) Import an existing CloudWatch composite alarm provided an Name.- Parameters:
scope
- The parent creating construct (usuallythis
). This parameter is required.id
- The construct's name. This parameter is required.compositeAlarmName
- Composite Alarm Name. This parameter is required.
-
getAlarmArn
ARN of this alarm.- Specified by:
getAlarmArn
in interfaceIAlarm
- Specified by:
getAlarmArn
in classAlarmBase
-
getAlarmName
Name of this alarm.- Specified by:
getAlarmName
in interfaceIAlarm
- Specified by:
getAlarmName
in classAlarmBase
-