"use strict";var _a;Object.defineProperty(exports,"__esModule",{value:!0}),exports.ResourcePolicy=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var secretsmanager_generated_1=()=>{var tmp=require("./secretsmanager.generated");return secretsmanager_generated_1=()=>tmp,tmp},iam=()=>{var tmp=require("../../aws-iam");return iam=()=>tmp,tmp},core_1=()=>{var tmp=require("../../core");return core_1=()=>tmp,tmp};class ResourcePolicy extends core_1().Resource{constructor(scope,id,props){super(scope,id),this.document=new(iam()).PolicyDocument;try{jsiiDeprecationWarnings().aws_cdk_lib_aws_secretsmanager_ResourcePolicyProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,ResourcePolicy),error}new(secretsmanager_generated_1()).CfnResourcePolicy(this,"Resource",{resourcePolicy:this.document,secretId:props.secret.secretArn})}}exports.ResourcePolicy=ResourcePolicy,_a=JSII_RTTI_SYMBOL_1,ResourcePolicy[_a]={fqn:"aws-cdk-lib.aws_secretsmanager.ResourcePolicy",version:"2.159.0"};
