Interface PolicyAttributes

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Implementing Classes:
PolicyAttributes.Jsii$Proxy

@Generated(value="jsii-pacmak/1.140.0 (build 79fd58c)", date="2026-09-25T13:53:45.537Z") @Stability(Stable) public interface PolicyAttributes extends software.amazon.jsii.JsiiSerializable
Attributes for importing an existing Policy.

Example:

 IPolicyEngine importedEngine = PolicyEngine.fromPolicyEngineAttributes(this, "ImportedEngine", PolicyEngineAttributes.builder()
         .policyEngineArn("policy-engine/my-engine-id")
         .build());
 IPolicy importedPolicy = Policy.fromPolicyAttributes(this, "ImportedPolicy", PolicyAttributes.builder()
         .policyArn("my-policy-arn")
         .policyEngine(importedEngine)
         .build());
 // Grant permissions to the imported policy
 Role role = Role.Builder.create(this, "PolicyRole")
         .assumedBy(new ServicePrincipal("lambda.amazonaws.com"))
         .build();
 importedPolicy.grantRead(role);