Class CfnPermissionAssociation

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, IEnvironmentAware, IPermissionAssociationRef, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.140.0 (build 79fd58c)", date="2026-10-08T17:00:02.019Z") @Stability(Stable) public class CfnPermissionAssociation extends CfnResource implements IInspectable, IPermissionAssociationRef
Associates a specified AWS RAM permission with a resource share.

You can only associate one permission with each resource type in a resource share.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.ram.*;
 CfnPermissionAssociation cfnPermissionAssociation = CfnPermissionAssociation.Builder.create(this, "MyCfnPermissionAssociation")
         .permissionArn("permissionArn")
         .resourceShareArn("resourceShareArn")
         // the properties below are optional
         .replace(false)
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnPermissionAssociation

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

      protected CfnPermissionAssociation(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnPermissionAssociation

      @Stability(Stable) public CfnPermissionAssociation(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnPermissionAssociationProps props)
      Create a new AWS::RAM::PermissionAssociation.

      Parameters:
      scope - Scope in which this resource is defined. This parameter is required.
      id - Construct identifier for this resource (unique in its scope). This parameter is required.
      props - Resource properties. This parameter is required.
  • Method Details

    • isCfnPermissionAssociation

      @Stability(Stable) @NotNull public static Boolean isCfnPermissionAssociation(@NotNull Object x)
      Checks whether the given object is a CfnPermissionAssociation.

      Parameters:
      x - This parameter is required.
    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector - tree inspector to collect and process attributes. This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrAssociationStatus

      @Stability(Stable) @NotNull public String getAttrAssociationStatus()
      The current status of the association between the permission and the resource share.
    • getAttrFeatureSet

      @Stability(Stable) @NotNull public String getAttrFeatureSet()
      The feature set of the resource share.
    • getAttrIsDefault

      @Stability(Stable) @NotNull public IResolvable getAttrIsDefault()
      Indicates whether the associated resource share is using the default version of the permission.
    • getAttrLastUpdatedTime

      @Stability(Stable) @NotNull public String getAttrLastUpdatedTime()
      The date and time when the association between the permission and the resource share was last updated.
    • getAttrPermissionVersion

      @Stability(Stable) @NotNull public String getAttrPermissionVersion()
      The version of the permission currently associated with the resource share.
    • getAttrResourceType

      @Stability(Stable) @NotNull public String getAttrResourceType()
      The resource type to which the permission applies.
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getCfnPropertyNames

      @Stability(Stable) @NotNull protected Map<String,String> getCfnPropertyNames()
      Overrides:
      getCfnPropertyNames in class CfnResource
    • getPermissionAssociationRef

      @Stability(Stable) @NotNull public PermissionAssociationReference getPermissionAssociationRef()
      A reference to a PermissionAssociation resource.
      Specified by:
      getPermissionAssociationRef in interface IPermissionAssociationRef
    • getPermissionArn

      @Stability(Stable) @NotNull public String getPermissionArn()
      Specifies the Amazon Resource Name (ARN) of the AWS RAM permission to associate with the resource share.
    • setPermissionArn

      @Stability(Stable) public void setPermissionArn(@NotNull String value)
      Specifies the Amazon Resource Name (ARN) of the AWS RAM permission to associate with the resource share.
    • getResourceShareArn

      @Stability(Stable) @NotNull public String getResourceShareArn()
      Specifies the Amazon Resource Name (ARN) of the resource share.
    • setResourceShareArn

      @Stability(Stable) public void setResourceShareArn(@NotNull String value)
      Specifies the Amazon Resource Name (ARN) of the resource share.
    • getReplace

      @Stability(Stable) @Nullable public Object getReplace()
      Specifies whether to replace the existing permission on the resource share.

      Returns union: either Boolean or IResolvable

    • setReplace

      @Stability(Stable) public void setReplace(@Nullable Boolean value)
      Specifies whether to replace the existing permission on the resource share.
    • setReplace

      @Stability(Stable) public void setReplace(@Nullable IResolvable value)
      Specifies whether to replace the existing permission on the resource share.