"use strict";var _a;Object.defineProperty(exports,"__esModule",{value:!0}),exports.KubernetesObjectValue=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var constructs_1=()=>{var tmp=require("constructs");return constructs_1=()=>tmp,tmp},kubectl_provider_1=()=>{var tmp=require("./kubectl-provider");return kubectl_provider_1=()=>tmp,tmp},core_1=()=>{var tmp=require("../../core");return core_1=()=>tmp,tmp};class KubernetesObjectValue extends constructs_1().Construct{constructor(scope,id,props){super(scope,id);try{jsiiDeprecationWarnings().aws_cdk_lib_aws_eks_KubernetesObjectValueProps(props)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,KubernetesObjectValue),error}const provider=kubectl_provider_1().KubectlProvider.getOrCreate(this,props.cluster);this._resource=new(core_1()).CustomResource(this,"Resource",{resourceType:KubernetesObjectValue.RESOURCE_TYPE,serviceToken:provider.serviceToken,properties:{ClusterName:props.cluster.clusterName,RoleArn:provider.roleArn,ObjectType:props.objectType,ObjectName:props.objectName,ObjectNamespace:props.objectNamespace??"default",JsonPath:props.jsonPath,TimeoutSeconds:(props?.timeout??core_1().Duration.minutes(5)).toSeconds()}})}get value(){return core_1().Token.asString(this._resource.getAtt("Value"))}}exports.KubernetesObjectValue=KubernetesObjectValue,_a=JSII_RTTI_SYMBOL_1,KubernetesObjectValue[_a]={fqn:"aws-cdk-lib.aws_eks.KubernetesObjectValue",version:"2.148.1"},KubernetesObjectValue.RESOURCE_TYPE="Custom::AWSCDK-EKS-KubernetesObjectValue";
