Interface ModifyImageAttributeRequest.Builder

All Superinterfaces:
AwsRequest.Builder, Buildable, CopyableBuilder<ModifyImageAttributeRequest.Builder,ModifyImageAttributeRequest>, Ec2Request.Builder, SdkBuilder<ModifyImageAttributeRequest.Builder,ModifyImageAttributeRequest>, SdkPojo, SdkRequest.Builder
Enclosing class:
ModifyImageAttributeRequest

public static interface ModifyImageAttributeRequest.Builder extends Ec2Request.Builder, SdkPojo, CopyableBuilder<ModifyImageAttributeRequest.Builder,ModifyImageAttributeRequest>
  • Method Details

    • attribute

      The name of the attribute to modify.

      Valid values: description | imdsSupport | launchPermission

      Parameters:
      attribute - The name of the attribute to modify.

      Valid values: description | imdsSupport | launchPermission

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • description

      A new description for the AMI.

      Parameters:
      description - A new description for the AMI.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • description

      A new description for the AMI.

      This is a convenience method that creates an instance of the AttributeValue.Builder avoiding the need to create one manually via AttributeValue.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to description(AttributeValue).

      Parameters:
      description - a consumer that will call methods on AttributeValue.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • imageId

      The ID of the AMI.

      Parameters:
      imageId - The ID of the AMI.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • launchPermission

      A new launch permission for the AMI.

      Parameters:
      launchPermission - A new launch permission for the AMI.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • launchPermission

      A new launch permission for the AMI.

      This is a convenience method that creates an instance of the LaunchPermissionModifications.Builder avoiding the need to create one manually via LaunchPermissionModifications.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to launchPermission(LaunchPermissionModifications).

      Parameters:
      launchPermission - a consumer that will call methods on LaunchPermissionModifications.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • operationType

      ModifyImageAttributeRequest.Builder operationType(String operationType)

      The operation type. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      operationType - The operation type. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • operationType

      ModifyImageAttributeRequest.Builder operationType(OperationType operationType)

      The operation type. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      operationType - The operation type. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • productCodes

      Not supported.

      Parameters:
      productCodes - Not supported.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • productCodes

      ModifyImageAttributeRequest.Builder productCodes(String... productCodes)

      Not supported.

      Parameters:
      productCodes - Not supported.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • userGroups

      The user groups. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      userGroups - The user groups. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • userGroups

      ModifyImageAttributeRequest.Builder userGroups(String... userGroups)

      The user groups. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      userGroups - The user groups. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • userIds

      The Amazon Web Services account IDs. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      userIds - The Amazon Web Services account IDs. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • userIds

      The Amazon Web Services account IDs. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      userIds - The Amazon Web Services account IDs. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • value

      The value of the attribute being modified. This parameter can be used only when the Attribute parameter is description or imdsSupport.

      Parameters:
      value - The value of the attribute being modified. This parameter can be used only when the Attribute parameter is description or imdsSupport.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • dryRun

      Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

      Parameters:
      dryRun - Checks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • organizationArns

      ModifyImageAttributeRequest.Builder organizationArns(Collection<String> organizationArns)

      The Amazon Resource Name (ARN) of an organization. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      organizationArns - The Amazon Resource Name (ARN) of an organization. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • organizationArns

      ModifyImageAttributeRequest.Builder organizationArns(String... organizationArns)

      The Amazon Resource Name (ARN) of an organization. This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      organizationArns - The Amazon Resource Name (ARN) of an organization. This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • organizationalUnitArns

      ModifyImageAttributeRequest.Builder organizationalUnitArns(Collection<String> organizationalUnitArns)

      The Amazon Resource Name (ARN) of an organizational unit (OU). This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      organizationalUnitArns - The Amazon Resource Name (ARN) of an organizational unit (OU). This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • organizationalUnitArns

      ModifyImageAttributeRequest.Builder organizationalUnitArns(String... organizationalUnitArns)

      The Amazon Resource Name (ARN) of an organizational unit (OU). This parameter can be used only when the Attribute parameter is launchPermission.

      Parameters:
      organizationalUnitArns - The Amazon Resource Name (ARN) of an organizational unit (OU). This parameter can be used only when the Attribute parameter is launchPermission.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • imdsSupport

      Set to v2.0 to indicate that IMDSv2 is specified in the AMI. Instances launched from this AMI will have HttpTokens automatically set to required so that, by default, the instance requires that IMDSv2 is used when requesting instance metadata. In addition, HttpPutResponseHopLimit is set to 2. For more information, see Configure the AMI in the Amazon EC2 User Guide.

      Do not use this parameter unless your AMI software supports IMDSv2. After you set the value to v2.0, you can't undo it. The only way to “reset” your AMI is to create a new AMI from the underlying snapshot.

      Parameters:
      imdsSupport - Set to v2.0 to indicate that IMDSv2 is specified in the AMI. Instances launched from this AMI will have HttpTokens automatically set to required so that, by default, the instance requires that IMDSv2 is used when requesting instance metadata. In addition, HttpPutResponseHopLimit is set to 2. For more information, see Configure the AMI in the Amazon EC2 User Guide.

      Do not use this parameter unless your AMI software supports IMDSv2. After you set the value to v2.0, you can't undo it. The only way to “reset” your AMI is to create a new AMI from the underlying snapshot.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • imdsSupport

      Set to v2.0 to indicate that IMDSv2 is specified in the AMI. Instances launched from this AMI will have HttpTokens automatically set to required so that, by default, the instance requires that IMDSv2 is used when requesting instance metadata. In addition, HttpPutResponseHopLimit is set to 2. For more information, see Configure the AMI in the Amazon EC2 User Guide.

      Do not use this parameter unless your AMI software supports IMDSv2. After you set the value to v2.0, you can't undo it. The only way to “reset” your AMI is to create a new AMI from the underlying snapshot.

      This is a convenience method that creates an instance of the AttributeValue.Builder avoiding the need to create one manually via AttributeValue.builder().

      When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to imdsSupport(AttributeValue).

      Parameters:
      imdsSupport - a consumer that will call methods on AttributeValue.Builder
      Returns:
      Returns a reference to this object so that method calls can be chained together.
      See Also:
    • overrideConfiguration

      ModifyImageAttributeRequest.Builder overrideConfiguration(AwsRequestOverrideConfiguration overrideConfiguration)
      Description copied from interface: AwsRequest.Builder
      Add an optional request override configuration.
      Specified by:
      overrideConfiguration in interface AwsRequest.Builder
      Parameters:
      overrideConfiguration - The override configuration.
      Returns:
      This object for method chaining.
    • overrideConfiguration

      Description copied from interface: AwsRequest.Builder
      Add an optional request override configuration.
      Specified by:
      overrideConfiguration in interface AwsRequest.Builder
      Parameters:
      builderConsumer - A Consumer to which an empty AwsRequestOverrideConfiguration.Builder will be given.
      Returns:
      This object for method chaining.