Class CreateImageRequest
- All Implemented Interfaces:
ReadLimitInfo
,DryRunSupportedRequest<CreateImageRequest>
,Serializable
,Cloneable
Contains the parameters for CreateImage.
- See Also:
-
Field Summary
Fields inherited from class com.amazonaws.AmazonWebServiceRequest
NOOP
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor for CreateImageRequest object.CreateImageRequest
(String instanceId, String name) Constructs a new CreateImageRequest object. -
Method Summary
Modifier and TypeMethodDescriptionclone()
Creates a shallow clone of this request.boolean
Information about one or more block device mappings.A description for the new image.This method is intended for internal use only.The ID of the instance.getName()
A name for the new image.By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image.int
hashCode()
By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image.void
setBlockDeviceMappings
(Collection<BlockDeviceMapping> blockDeviceMappings) Information about one or more block device mappings.void
setDescription
(String description) A description for the new image.void
setInstanceId
(String instanceId) The ID of the instance.void
A name for the new image.void
setNoReboot
(Boolean noReboot) By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image.toString()
Returns a string representation of this object; useful for testing and debugging.withBlockDeviceMappings
(BlockDeviceMapping... blockDeviceMappings) Information about one or more block device mappings.withBlockDeviceMappings
(Collection<BlockDeviceMapping> blockDeviceMappings) Information about one or more block device mappings.withDescription
(String description) A description for the new image.withInstanceId
(String instanceId) The ID of the instance.A name for the new image.withNoReboot
(Boolean noReboot) By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image.Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyBaseTo, getCloneRoot, getCloneSource, getCustomQueryParameters, getCustomRequestHeaders, getGeneralProgressListener, getReadLimit, getRequestClientOptions, getRequestCredentials, getRequestCredentialsProvider, getRequestMetricCollector, getSdkClientExecutionTimeout, getSdkRequestTimeout, putCustomQueryParameter, putCustomRequestHeader, setGeneralProgressListener, setRequestCredentials, setRequestCredentialsProvider, setRequestMetricCollector, setSdkClientExecutionTimeout, setSdkRequestTimeout, withGeneralProgressListener, withRequestMetricCollector, withSdkClientExecutionTimeout, withSdkRequestTimeout
-
Constructor Details
-
CreateImageRequest
public CreateImageRequest()Default constructor for CreateImageRequest object. Callers should use the setter or fluent setter (with...) methods to initialize the object after creating it. -
CreateImageRequest
Constructs a new CreateImageRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.- Parameters:
instanceId
- The ID of the instance.name
- A name for the new image.Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
-
-
Method Details
-
setInstanceId
The ID of the instance.
- Parameters:
instanceId
- The ID of the instance.
-
getInstanceId
The ID of the instance.
- Returns:
- The ID of the instance.
-
withInstanceId
The ID of the instance.
- Parameters:
instanceId
- The ID of the instance.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setName
A name for the new image.
Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
- Parameters:
name
- A name for the new image.Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
-
getName
A name for the new image.
Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
- Returns:
- A name for the new image.
Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
-
withName
A name for the new image.
Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
- Parameters:
name
- A name for the new image.Constraints: 3-128 alphanumeric characters, parentheses (()), square brackets ([]), spaces ( ), periods (.), slashes (/), dashes (-), single quotes ('), at-signs (@), or underscores(_)
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setDescription
A description for the new image.
- Parameters:
description
- A description for the new image.
-
getDescription
A description for the new image.
- Returns:
- A description for the new image.
-
withDescription
A description for the new image.
- Parameters:
description
- A description for the new image.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setNoReboot
By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
- Parameters:
noReboot
- By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
-
getNoReboot
By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
- Returns:
- By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
-
withNoReboot
By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
- Parameters:
noReboot
- By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isNoReboot
By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
- Returns:
- By default, Amazon EC2 attempts to shut down and reboot the instance before creating the image. If the 'No Reboot' option is set, Amazon EC2 doesn't shut down the instance before creating the image. When this option is used, file system integrity on the created image can't be guaranteed.
-
getBlockDeviceMappings
Information about one or more block device mappings.
- Returns:
- Information about one or more block device mappings.
-
setBlockDeviceMappings
Information about one or more block device mappings.
- Parameters:
blockDeviceMappings
- Information about one or more block device mappings.
-
withBlockDeviceMappings
Information about one or more block device mappings.
NOTE: This method appends the values to the existing list (if any). Use
setBlockDeviceMappings(java.util.Collection)
orwithBlockDeviceMappings(java.util.Collection)
if you want to override the existing values.- Parameters:
blockDeviceMappings
- Information about one or more block device mappings.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
withBlockDeviceMappings
public CreateImageRequest withBlockDeviceMappings(Collection<BlockDeviceMapping> blockDeviceMappings) Information about one or more block device mappings.
- Parameters:
blockDeviceMappings
- Information about one or more block device mappings.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
getDryRunRequest
This method is intended for internal use only. Returns the marshaled request configured with additional parameters to enable operation dry-run.- Specified by:
getDryRunRequest
in interfaceDryRunSupportedRequest<CreateImageRequest>
-
toString
Returns a string representation of this object; useful for testing and debugging. -
equals
-
hashCode
public int hashCode() -
clone
Description copied from class:AmazonWebServiceRequest
Creates a shallow clone of this request. Explicitly does not clone the deep structure of the request object.- Overrides:
clone
in classAmazonWebServiceRequest
- See Also:
-