Class DetachVolumeRequest
- java.lang.Object
-
- com.amazonaws.AmazonWebServiceRequest
-
- com.amazonaws.services.ec2.model.DetachVolumeRequest
-
- All Implemented Interfaces:
ReadLimitInfo
,DryRunSupportedRequest<DetachVolumeRequest>
,Serializable
,Cloneable
public class DetachVolumeRequest extends AmazonWebServiceRequest implements Serializable, Cloneable, DryRunSupportedRequest<DetachVolumeRequest>
Contains the parameters for DetachVolume.
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.amazonaws.AmazonWebServiceRequest
NOOP
-
-
Constructor Summary
Constructors Constructor Description DetachVolumeRequest()
Default constructor for DetachVolumeRequest object.DetachVolumeRequest(String volumeId)
Constructs a new DetachVolumeRequest object.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DetachVolumeRequest
clone()
Creates a shallow clone of this request.boolean
equals(Object obj)
String
getDevice()
The device name.Request<DetachVolumeRequest>
getDryRunRequest()
This method is intended for internal use only.Boolean
getForce()
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally).String
getInstanceId()
The ID of the instance.String
getVolumeId()
The ID of the volume.int
hashCode()
Boolean
isForce()
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally).void
setDevice(String device)
The device name.void
setForce(Boolean force)
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally).void
setInstanceId(String instanceId)
The ID of the instance.void
setVolumeId(String volumeId)
The ID of the volume.String
toString()
Returns a string representation of this object; useful for testing and debugging.DetachVolumeRequest
withDevice(String device)
The device name.DetachVolumeRequest
withForce(Boolean force)
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally).DetachVolumeRequest
withInstanceId(String instanceId)
The ID of the instance.DetachVolumeRequest
withVolumeId(String volumeId)
The ID of the volume.-
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 Detail
-
DetachVolumeRequest
public DetachVolumeRequest()
Default constructor for DetachVolumeRequest object. Callers should use the setter or fluent setter (with...) methods to initialize the object after creating it.
-
DetachVolumeRequest
public DetachVolumeRequest(String volumeId)
Constructs a new DetachVolumeRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.- Parameters:
volumeId
- The ID of the volume.
-
-
Method Detail
-
setVolumeId
public void setVolumeId(String volumeId)
The ID of the volume.
- Parameters:
volumeId
- The ID of the volume.
-
getVolumeId
public String getVolumeId()
The ID of the volume.
- Returns:
- The ID of the volume.
-
withVolumeId
public DetachVolumeRequest withVolumeId(String volumeId)
The ID of the volume.
- Parameters:
volumeId
- The ID of the volume.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setInstanceId
public void setInstanceId(String instanceId)
The ID of the instance.
- Parameters:
instanceId
- The ID of the instance.
-
getInstanceId
public String getInstanceId()
The ID of the instance.
- Returns:
- The ID of the instance.
-
withInstanceId
public DetachVolumeRequest withInstanceId(String instanceId)
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.
-
setDevice
public void setDevice(String device)
The device name.
- Parameters:
device
- The device name.
-
getDevice
public String getDevice()
The device name.
- Returns:
- The device name.
-
withDevice
public DetachVolumeRequest withDevice(String device)
The device name.
- Parameters:
device
- The device name.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setForce
public void setForce(Boolean force)
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
- Parameters:
force
- Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
-
getForce
public Boolean getForce()
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
- Returns:
- Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
-
withForce
public DetachVolumeRequest withForce(Boolean force)
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
- Parameters:
force
- Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
isForce
public Boolean isForce()
Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
- Returns:
- Forces detachment if the previous detachment attempt did not occur cleanly (for example, logging into an instance, unmounting the volume, and detaching normally). This option can lead to data loss or a corrupted file system. Use this option only as a last resort to detach a volume from a failed instance. The instance won't have an opportunity to flush file system caches or file system metadata. If you use this option, you must perform file system check and repair procedures.
-
getDryRunRequest
public Request<DetachVolumeRequest> 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<DetachVolumeRequest>
-
toString
public String toString()
Returns a string representation of this object; useful for testing and debugging.- Overrides:
toString
in classObject
- Returns:
- A string representation of this object.
- See Also:
Object.toString()
-
clone
public DetachVolumeRequest 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:
Object.clone()
-
-