Class AccessKeyProps.Builder

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

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

    • Builder

      public Builder()
  • Method Details

    • user

      @Stability(Stable) public AccessKeyProps.Builder user(IUser user)
      Sets the value of AccessKeyProps.getUser()
      Parameters:
      user - The IAM user this key will belong to. This parameter is required. Changing this value will result in the access key being deleted and a new access key (with a different ID and secret value) being assigned to the new user.
      Returns:
      this
    • serial

      @Stability(Stable) public AccessKeyProps.Builder serial(Number serial)
      Sets the value of AccessKeyProps.getSerial()
      Parameters:
      serial - A CloudFormation-specific value that signifies the access key should be replaced/rotated. This value can only be incremented. Incrementing this value will cause CloudFormation to replace the Access Key resource.
      Returns:
      this
    • status

      @Stability(Stable) public AccessKeyProps.Builder status(AccessKeyStatus status)
      Sets the value of AccessKeyProps.getStatus()
      Parameters:
      status - The status of the access key. An Active access key is allowed to be used to make API calls; An Inactive key cannot.
      Returns:
      this
    • build

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