Class PolicyResource

java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.services.bedrockagentcore.PolicyResource
All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable

@Generated(value="jsii-pacmak/1.139.0 (build 26a6b54)", date="2026-09-10T17:51:40.362Z") @Stability(Stable) public class PolicyResource extends software.amazon.jsii.JsiiObject
The resource a policy statement applies to.

AgentCore rejects a policy whose resource is an unconstrained wildcard, so a statement must name either a resource type or a specific resource.

Example:

 import software.amazon.awscdk.services.bedrockagentcore.PolicyResource;
 String gatewayArn;
 PolicyResource.anyOfType("AgentCore::Gateway"); // resource is AgentCore::Gateway
 PolicyResource.instance("AgentCore::Gateway", gatewayArn);
 
  • Nested Class Summary

    Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject

    software.amazon.jsii.JsiiObject.InitializationMode
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    PolicyResource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
     
    protected
    PolicyResource(software.amazon.jsii.JsiiObjectRef objRef)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    anyOfType(String entityType)
    Any resource of the given entity type.
    instance(String entityType, String entityArn)
    One specific resource.

    Methods inherited from class software.amazon.jsii.JsiiObject

    jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface software.amazon.jsii.JsiiSerializable

    $jsii$toJson
  • Constructor Details

    • PolicyResource

      protected PolicyResource(software.amazon.jsii.JsiiObjectRef objRef)
    • PolicyResource

      protected PolicyResource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
  • Method Details

    • anyOfType

      @Stability(Stable) @NotNull public static PolicyResource anyOfType(@NotNull String entityType)
      Any resource of the given entity type.

      Parameters:
      entityType -
      • The entity type, for example 'AgentCore::Gateway'.
      This parameter is required.
    • instance

      @Stability(Stable) @NotNull public static PolicyResource instance(@NotNull String entityType, @NotNull String entityArn)
      One specific resource.

      AgentCore requires a specific resource when the statement names specific actions rather than any action.

      Parameters:
      entityType -
      • The entity type, for example 'AgentCore::Gateway'.
      This parameter is required.
      entityArn -
      • The resource ARN or identifier.
      This parameter is required.