"use strict";var _a;Object.defineProperty(exports,"__esModule",{value:!0}),exports.FeatureFlags=void 0;const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti"),cxapi=require("../../cx-api");class FeatureFlags{constructor(construct){this.construct=construct}static of(scope){return new FeatureFlags(scope)}isEnabled(featureFlag){const context=this.construct.node.tryGetContext(featureFlag);if(cxapi.FUTURE_FLAGS_EXPIRED.includes(featureFlag)){if(context!==void 0)throw new Error(`Unsupported feature flag '${featureFlag}'. This flag existed on CDKv1 but has been removed in CDKv2. CDK will now behave as the same as when the flag is enabled.`);return!0}return context!=null?context:cxapi.futureFlagDefault(featureFlag)}}exports.FeatureFlags=FeatureFlags,_a=JSII_RTTI_SYMBOL_1,FeatureFlags[_a]={fqn:"aws-cdk-lib.FeatureFlags",version:"2.13.0"};
//# sourceMappingURL=feature-flags.js.map
