"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.AlarmBase=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var core_1=()=>{var tmp=require("../../core");return core_1=()=>tmp,tmp},helpers_internal_1=()=>{var tmp=require("../../core/lib/helpers-internal");return helpers_internal_1=()=>tmp,tmp};class AlarmBase extends core_1().Resource{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_cloudwatch.AlarmBase",version:"2.256.1"};_alarmActionArns=helpers_internal_1().Box.fromArray();_insufficientDataActionArns=helpers_internal_1().Box.fromArray();_okActionArns=helpers_internal_1().Box.fromArray();get alarmActionArns(){return this._alarmActionArns.length>0?[...this._alarmActionArns]:void 0}set alarmActionArns(value){this._alarmActionArns.set(value??[])}get insufficientDataActionArns(){return this._insufficientDataActionArns.length>0?[...this._insufficientDataActionArns]:void 0}set insufficientDataActionArns(value){this._insufficientDataActionArns.set(value??[])}get okActionArns(){return this._okActionArns.length>0?[...this._okActionArns]:void 0}set okActionArns(value){this._okActionArns.set(value??[])}get alarmRef(){return{alarmName:this.alarmName,alarmArn:this.alarmArn}}renderAlarmRule(){return`ALARM("${this.alarmArn}")`}addAlarmAction(...actions){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_cloudwatch_IAlarmAction(actions)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.addAlarmAction),error}this._alarmActionArns.push(...actions.map(a=>a.bind(this,this).alarmActionArn))}addInsufficientDataAction(...actions){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_cloudwatch_IAlarmAction(actions)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.addInsufficientDataAction),error}this._insufficientDataActionArns.push(...actions.map(a=>a.bind(this,this).alarmActionArn))}addOkAction(...actions){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_cloudwatch_IAlarmAction(actions)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.addOkAction),error}this._okActionArns.push(...actions.map(a=>a.bind(this,this).alarmActionArn))}}exports.AlarmBase=AlarmBase;
