com.amazonaws.services.ec2.model
Class RevokeSecurityGroupEgressRequest

java.lang.Object
  extended by com.amazonaws.AmazonWebServiceRequest
      extended by com.amazonaws.services.ec2.model.RevokeSecurityGroupEgressRequest
All Implemented Interfaces:
DryRunSupportedRequest<RevokeSecurityGroupEgressRequest>, java.io.Serializable

public class RevokeSecurityGroupEgressRequest
extends AmazonWebServiceRequest
implements java.io.Serializable, DryRunSupportedRequest<RevokeSecurityGroupEgressRequest>

Container for the parameters to the RevokeSecurityGroupEgress operation.

Removes one or more egress rules from a security group for EC2-VPC. The values that you specify in the revoke request (for example, ports) must match the existing rule's values for the rule to be revoked.

Each rule consists of the protocol and the CIDR range or source security group. For the TCP and UDP protocols, you must also specify the destination port or range of ports. For the ICMP protocol, you must also specify the ICMP type and code.

Rule changes are propagated to instances within the security group as quickly as possible. However, a small delay might occur.

See Also:
AmazonEC2.revokeSecurityGroupEgress(RevokeSecurityGroupEgressRequest), Serialized Form

Constructor Summary
RevokeSecurityGroupEgressRequest()
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 java.lang.String getCidrIp()
          The CIDR IP address range.
 Request<RevokeSecurityGroupEgressRequest> getDryRunRequest()
          This method is intended for internal use only.
 java.lang.Integer getFromPort()
          The start of port range for the TCP and UDP protocols, or an ICMP type number.
 java.lang.String getGroupId()
          The ID of the security group.
 java.util.List<IpPermission> getIpPermissions()
          

 java.lang.String getIpProtocol()
          The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers).
 java.lang.String getSourceSecurityGroupName()
          [EC2-Classic, default VPC] The name of the source security group.
 java.lang.String getSourceSecurityGroupOwnerId()
          The ID of the source security group.
 java.lang.Integer getToPort()
          The end of port range for the TCP and UDP protocols, or an ICMP code number.
 int hashCode()
           
 void setCidrIp(java.lang.String cidrIp)
          The CIDR IP address range.
 void setFromPort(java.lang.Integer fromPort)
          The start of port range for the TCP and UDP protocols, or an ICMP type number.
 void setGroupId(java.lang.String groupId)
          The ID of the security group.
 void setIpPermissions(java.util.Collection<IpPermission> ipPermissions)
          

 void setIpProtocol(java.lang.String ipProtocol)
          The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers).
 void setSourceSecurityGroupName(java.lang.String sourceSecurityGroupName)
          [EC2-Classic, default VPC] The name of the source security group.
 void setSourceSecurityGroupOwnerId(java.lang.String sourceSecurityGroupOwnerId)
          The ID of the source security group.
 void setToPort(java.lang.Integer toPort)
          The end of port range for the TCP and UDP protocols, or an ICMP code number.
 java.lang.String toString()
          Returns a string representation of this object; useful for testing and debugging.
 RevokeSecurityGroupEgressRequest withCidrIp(java.lang.String cidrIp)
          The CIDR IP address range.
 RevokeSecurityGroupEgressRequest withFromPort(java.lang.Integer fromPort)
          The start of port range for the TCP and UDP protocols, or an ICMP type number.
 RevokeSecurityGroupEgressRequest withGroupId(java.lang.String groupId)
          The ID of the security group.
 RevokeSecurityGroupEgressRequest withIpPermissions(java.util.Collection<IpPermission> ipPermissions)
          

 RevokeSecurityGroupEgressRequest withIpPermissions(IpPermission... ipPermissions)
          

 RevokeSecurityGroupEgressRequest withIpProtocol(java.lang.String ipProtocol)
          The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers).
 RevokeSecurityGroupEgressRequest withSourceSecurityGroupName(java.lang.String sourceSecurityGroupName)
          [EC2-Classic, default VPC] The name of the source security group.
 RevokeSecurityGroupEgressRequest withSourceSecurityGroupOwnerId(java.lang.String sourceSecurityGroupOwnerId)
          The ID of the source security group.
 RevokeSecurityGroupEgressRequest withToPort(java.lang.Integer toPort)
          The end of port range for the TCP and UDP protocols, or an ICMP code number.
 
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyPrivateRequestParameters, getDelegationToken, getRequestClientOptions, getRequestCredentials, getRequestMetricCollector, setDelegationToken, setRequestCredentials, setRequestMetricCollector, withRequestMetricCollector
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RevokeSecurityGroupEgressRequest

public RevokeSecurityGroupEgressRequest()
Method Detail

getGroupId

public java.lang.String getGroupId()
The ID of the security group.

Returns:
The ID of the security group.

setGroupId

public void setGroupId(java.lang.String groupId)
The ID of the security group.

Parameters:
groupId - The ID of the security group.

withGroupId

public RevokeSecurityGroupEgressRequest withGroupId(java.lang.String groupId)
The ID of the security group.

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

Parameters:
groupId - The ID of the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

getSourceSecurityGroupName

public java.lang.String getSourceSecurityGroupName()
[EC2-Classic, default VPC] The name of the source security group. You can't specify a source security group and a CIDR IP address range.

Returns:
[EC2-Classic, default VPC] The name of the source security group. You can't specify a source security group and a CIDR IP address range.

setSourceSecurityGroupName

public void setSourceSecurityGroupName(java.lang.String sourceSecurityGroupName)
[EC2-Classic, default VPC] The name of the source security group. You can't specify a source security group and a CIDR IP address range.

Parameters:
sourceSecurityGroupName - [EC2-Classic, default VPC] The name of the source security group. You can't specify a source security group and a CIDR IP address range.

withSourceSecurityGroupName

public RevokeSecurityGroupEgressRequest withSourceSecurityGroupName(java.lang.String sourceSecurityGroupName)
[EC2-Classic, default VPC] The name of the source security group. You can't specify a source security group and a CIDR IP address range.

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

Parameters:
sourceSecurityGroupName - [EC2-Classic, default VPC] The name of the source security group. You can't specify a source security group and a CIDR IP address range.
Returns:
A reference to this updated object so that method calls can be chained together.

getSourceSecurityGroupOwnerId

public java.lang.String getSourceSecurityGroupOwnerId()
The ID of the source security group. You can't specify a source security group and a CIDR IP address range.

Returns:
The ID of the source security group. You can't specify a source security group and a CIDR IP address range.

setSourceSecurityGroupOwnerId

public void setSourceSecurityGroupOwnerId(java.lang.String sourceSecurityGroupOwnerId)
The ID of the source security group. You can't specify a source security group and a CIDR IP address range.

Parameters:
sourceSecurityGroupOwnerId - The ID of the source security group. You can't specify a source security group and a CIDR IP address range.

withSourceSecurityGroupOwnerId

public RevokeSecurityGroupEgressRequest withSourceSecurityGroupOwnerId(java.lang.String sourceSecurityGroupOwnerId)
The ID of the source security group. You can't specify a source security group and a CIDR IP address range.

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

Parameters:
sourceSecurityGroupOwnerId - The ID of the source security group. You can't specify a source security group and a CIDR IP address range.
Returns:
A reference to this updated object so that method calls can be chained together.

getIpProtocol

public java.lang.String getIpProtocol()
The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). Use -1 to specify all.

Returns:
The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). Use -1 to specify all.

setIpProtocol

public void setIpProtocol(java.lang.String ipProtocol)
The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). Use -1 to specify all.

Parameters:
ipProtocol - The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). Use -1 to specify all.

withIpProtocol

public RevokeSecurityGroupEgressRequest withIpProtocol(java.lang.String ipProtocol)
The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). Use -1 to specify all.

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

Parameters:
ipProtocol - The IP protocol name (tcp, udp, icmp) or number (see Protocol Numbers). Use -1 to specify all.
Returns:
A reference to this updated object so that method calls can be chained together.

getFromPort

public java.lang.Integer getFromPort()
The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.

Returns:
The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.

setFromPort

public void setFromPort(java.lang.Integer fromPort)
The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.

Parameters:
fromPort - The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.

withFromPort

public RevokeSecurityGroupEgressRequest withFromPort(java.lang.Integer fromPort)
The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.

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

Parameters:
fromPort - The start of port range for the TCP and UDP protocols, or an ICMP type number. For the ICMP type number, use -1 to specify all ICMP types.
Returns:
A reference to this updated object so that method calls can be chained together.

getToPort

public java.lang.Integer getToPort()
The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.

Returns:
The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.

setToPort

public void setToPort(java.lang.Integer toPort)
The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.

Parameters:
toPort - The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.

withToPort

public RevokeSecurityGroupEgressRequest withToPort(java.lang.Integer toPort)
The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.

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

Parameters:
toPort - The end of port range for the TCP and UDP protocols, or an ICMP code number. For the ICMP code number, use -1 to specify all ICMP codes for the ICMP type.
Returns:
A reference to this updated object so that method calls can be chained together.

getCidrIp

public java.lang.String getCidrIp()
The CIDR IP address range. You can't specify this parameter when specifying a source security group.

Returns:
The CIDR IP address range. You can't specify this parameter when specifying a source security group.

setCidrIp

public void setCidrIp(java.lang.String cidrIp)
The CIDR IP address range. You can't specify this parameter when specifying a source security group.

Parameters:
cidrIp - The CIDR IP address range. You can't specify this parameter when specifying a source security group.

withCidrIp

public RevokeSecurityGroupEgressRequest withCidrIp(java.lang.String cidrIp)
The CIDR IP address range. You can't specify this parameter when specifying a source security group.

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

Parameters:
cidrIp - The CIDR IP address range. You can't specify this parameter when specifying a source security group.
Returns:
A reference to this updated object so that method calls can be chained together.

getIpPermissions

public java.util.List<IpPermission> getIpPermissions()

Returns:


setIpPermissions

public void setIpPermissions(java.util.Collection<IpPermission> ipPermissions)

Parameters:
ipPermissions -


withIpPermissions

public RevokeSecurityGroupEgressRequest withIpPermissions(IpPermission... ipPermissions)

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

Parameters:
ipPermissions -

Returns:
A reference to this updated object so that method calls can be chained together.

withIpPermissions

public RevokeSecurityGroupEgressRequest withIpPermissions(java.util.Collection<IpPermission> ipPermissions)

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

Parameters:
ipPermissions -

Returns:
A reference to this updated object so that method calls can be chained together.

getDryRunRequest

public Request<RevokeSecurityGroupEgressRequest> 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 interface DryRunSupportedRequest<RevokeSecurityGroupEgressRequest>

toString

public java.lang.String toString()
Returns a string representation of this object; useful for testing and debugging.

Overrides:
toString in class java.lang.Object
Returns:
A string representation of this object.
See Also:
Object.toString()

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object


Copyright © 2010 Amazon Web Services, Inc. All Rights Reserved.