Class CfnAccessGrantProps.Builder

java.lang.Object
software.amazon.awscdk.services.s3.CfnAccessGrantProps.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CfnAccessGrantProps>
Enclosing interface:
CfnAccessGrantProps

@Stability(Stable) public static final class CfnAccessGrantProps.Builder extends Object implements software.amazon.jsii.Builder<CfnAccessGrantProps>
A builder for CfnAccessGrantProps
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • accessGrantsLocationId

      @Stability(Stable) public CfnAccessGrantProps.Builder accessGrantsLocationId(String accessGrantsLocationId)
      Parameters:
      accessGrantsLocationId - The ID of the registered location to which you are granting access. This parameter is required. S3 Access Grants assigns this ID when you register the location. S3 Access Grants assigns the ID default to the default location s3:// and assigns an auto-generated ID to other locations that you register.
      Returns:
      this
    • grantee

      @Stability(Stable) public CfnAccessGrantProps.Builder grantee(IResolvable grantee)
      Parameters:
      grantee - The user, group, or role to which you are granting access. This parameter is required. You can grant access to an IAM user or role. If you have added your corporate directory to AWS IAM Identity Center and associated your Identity Center instance with your S3 Access Grants instance, the grantee can also be a corporate directory user or group.
      Returns:
      this
    • grantee

      @Stability(Stable) public CfnAccessGrantProps.Builder grantee(CfnAccessGrant.GranteeProperty grantee)
      Parameters:
      grantee - The user, group, or role to which you are granting access. This parameter is required. You can grant access to an IAM user or role. If you have added your corporate directory to AWS IAM Identity Center and associated your Identity Center instance with your S3 Access Grants instance, the grantee can also be a corporate directory user or group.
      Returns:
      this
    • permission

      @Stability(Stable) public CfnAccessGrantProps.Builder permission(String permission)
      Parameters:
      permission - The type of access that you are granting to your S3 data, which can be set to one of the following values: - READ – Grant read-only access to the S3 data. This parameter is required.
      • WRITE – Grant write-only access to the S3 data.
      • READWRITE – Grant both read and write access to the S3 data.
      Returns:
      this
    • accessGrantsLocationConfiguration

      @Stability(Stable) public CfnAccessGrantProps.Builder accessGrantsLocationConfiguration(IResolvable accessGrantsLocationConfiguration)
      Parameters:
      accessGrantsLocationConfiguration - The configuration options of the grant location. The grant location is the S3 path to the data to which you are granting access. It contains the S3SubPrefix field. The grant scope is the result of appending the subprefix to the location scope of the registered location.
      Returns:
      this
    • accessGrantsLocationConfiguration

      @Stability(Stable) public CfnAccessGrantProps.Builder accessGrantsLocationConfiguration(CfnAccessGrant.AccessGrantsLocationConfigurationProperty accessGrantsLocationConfiguration)
      Parameters:
      accessGrantsLocationConfiguration - The configuration options of the grant location. The grant location is the S3 path to the data to which you are granting access. It contains the S3SubPrefix field. The grant scope is the result of appending the subprefix to the location scope of the registered location.
      Returns:
      this
    • applicationArn

      @Stability(Stable) public CfnAccessGrantProps.Builder applicationArn(String applicationArn)
      Parameters:
      applicationArn - The Amazon Resource Name (ARN) of an AWS IAM Identity Center application associated with your Identity Center instance. If the grant includes an application ARN, the grantee can only access the S3 data through this application.
      Returns:
      this
    • s3PrefixType

      @Stability(Stable) public CfnAccessGrantProps.Builder s3PrefixType(String s3PrefixType)
      Parameters:
      s3PrefixType - The type of S3SubPrefix . The only possible value is Object . Pass this value if the access grant scope is an object. Do not pass this value if the access grant scope is a bucket or a bucket and a prefix.
      Returns:
      this
    • tags

      @Stability(Stable) public CfnAccessGrantProps.Builder tags(List<? extends CfnTag> tags)
      Parameters:
      tags - The AWS resource tags that you are adding to the access grant. Each tag is a label consisting of a user-defined key and value. Tags can help you manage, identify, organize, search for, and filter resources.
      Returns:
      this
    • build

      @Stability(Stable) public CfnAccessGrantProps build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnAccessGrantProps>
      Returns:
      a new instance of CfnAccessGrantProps
      Throws:
      NullPointerException - if any required attribute was not provided