public class ReleaseAddressRequest extends AmazonWebServiceRequest implements Serializable, DryRunSupportedRequest<ReleaseAddressRequest>
ReleaseAddress operation
.
Releases the specified Elastic IP address.
After releasing an Elastic IP address, it is released to the IP
address pool and might be unavailable to you. Be sure to update your
DNS records and any servers or devices that communicate with the
address. If you attempt to release an Elastic IP address that you
already released, you'll get an AuthFailure
error if the
address is already allocated to another AWS account.
[EC2-Classic, default VPC] Releasing an Elastic IP address automatically disassociates it from any instance that it's associated with. To disassociate an Elastic IP address without releasing it, use DisassociateAddress.
[Nondefault VPC] You must use the DisassociateAddress to disassociate
the Elastic IP address before you try to release it. Otherwise, Amazon
EC2 returns an error ( InvalidIPAddress.InUse
).
NOOP
Constructor and Description |
---|
ReleaseAddressRequest()
Default constructor for a new ReleaseAddressRequest object.
|
ReleaseAddressRequest(String publicIp)
Constructs a new ReleaseAddressRequest object.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
String |
getAllocationId()
[EC2-VPC] The allocation ID.
|
Request<ReleaseAddressRequest> |
getDryRunRequest()
This method is intended for internal use only.
|
String |
getPublicIp()
[EC2-Classic] The Elastic IP address.
|
int |
hashCode() |
void |
setAllocationId(String allocationId)
[EC2-VPC] The allocation ID.
|
void |
setPublicIp(String publicIp)
[EC2-Classic] The Elastic IP address.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
ReleaseAddressRequest |
withAllocationId(String allocationId)
[EC2-VPC] The allocation ID.
|
ReleaseAddressRequest |
withPublicIp(String publicIp)
[EC2-Classic] The Elastic IP address.
|
copyPrivateRequestParameters, getGeneralProgressListener, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setGeneralProgressListener, setRequestCredentials, setRequestMetricCollector, withGeneralProgressListener, withRequestMetricCollector
public ReleaseAddressRequest()
public ReleaseAddressRequest(String publicIp)
publicIp
- [EC2-Classic] The Elastic IP address.public String getPublicIp()
public void setPublicIp(String publicIp)
publicIp
- [EC2-Classic] The Elastic IP address.public ReleaseAddressRequest withPublicIp(String publicIp)
Returns a reference to this object so that method calls can be chained together.
publicIp
- [EC2-Classic] The Elastic IP address.public String getAllocationId()
public void setAllocationId(String allocationId)
allocationId
- [EC2-VPC] The allocation ID.public ReleaseAddressRequest withAllocationId(String allocationId)
Returns a reference to this object so that method calls can be chained together.
allocationId
- [EC2-VPC] The allocation ID.public Request<ReleaseAddressRequest> getDryRunRequest()
getDryRunRequest
in interface DryRunSupportedRequest<ReleaseAddressRequest>
public String toString()
toString
in class Object
Object.toString()
Copyright © 2014. All rights reserved.