com.amazonaws.services.ec2.model
Class SecurityGroup

java.lang.Object
  extended by com.amazonaws.services.ec2.model.SecurityGroup
All Implemented Interfaces:
java.io.Serializable

public class SecurityGroup
extends java.lang.Object
implements java.io.Serializable

Describes a security group

See Also:
Serialized Form

Constructor Summary
SecurityGroup()
           
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 java.lang.String getDescription()
          A description of the security group.
 java.lang.String getGroupId()
          The ID of the security group.
 java.lang.String getGroupName()
          The name of the security group.
 java.util.List<IpPermission> getIpPermissions()
          One or more inbound rules associated with the security group.
 java.util.List<IpPermission> getIpPermissionsEgress()
          [EC2-VPC] One or more outbound rules associated with the security group.
 java.lang.String getOwnerId()
          The AWS account ID of the owner of the security group.
 java.util.List<Tag> getTags()
          Any tags assigned to the security group.
 java.lang.String getVpcId()
          [EC2-VPC] The ID of the VPC for the security group.
 int hashCode()
           
 void setDescription(java.lang.String description)
          A description of the security group.
 void setGroupId(java.lang.String groupId)
          The ID of the security group.
 void setGroupName(java.lang.String groupName)
          The name of the security group.
 void setIpPermissions(java.util.Collection<IpPermission> ipPermissions)
          One or more inbound rules associated with the security group.
 void setIpPermissionsEgress(java.util.Collection<IpPermission> ipPermissionsEgress)
          [EC2-VPC] One or more outbound rules associated with the security group.
 void setOwnerId(java.lang.String ownerId)
          The AWS account ID of the owner of the security group.
 void setTags(java.util.Collection<Tag> tags)
          Any tags assigned to the security group.
 void setVpcId(java.lang.String vpcId)
          [EC2-VPC] The ID of the VPC for the security group.
 java.lang.String toString()
          Returns a string representation of this object; useful for testing and debugging.
 SecurityGroup withDescription(java.lang.String description)
          A description of the security group.
 SecurityGroup withGroupId(java.lang.String groupId)
          The ID of the security group.
 SecurityGroup withGroupName(java.lang.String groupName)
          The name of the security group.
 SecurityGroup withIpPermissions(java.util.Collection<IpPermission> ipPermissions)
          One or more inbound rules associated with the security group.
 SecurityGroup withIpPermissions(IpPermission... ipPermissions)
          One or more inbound rules associated with the security group.
 SecurityGroup withIpPermissionsEgress(java.util.Collection<IpPermission> ipPermissionsEgress)
          [EC2-VPC] One or more outbound rules associated with the security group.
 SecurityGroup withIpPermissionsEgress(IpPermission... ipPermissionsEgress)
          [EC2-VPC] One or more outbound rules associated with the security group.
 SecurityGroup withOwnerId(java.lang.String ownerId)
          The AWS account ID of the owner of the security group.
 SecurityGroup withTags(java.util.Collection<Tag> tags)
          Any tags assigned to the security group.
 SecurityGroup withTags(Tag... tags)
          Any tags assigned to the security group.
 SecurityGroup withVpcId(java.lang.String vpcId)
          [EC2-VPC] The ID of the VPC for the security group.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SecurityGroup

public SecurityGroup()
Method Detail

getOwnerId

public java.lang.String getOwnerId()
The AWS account ID of the owner of the security group.

Returns:
The AWS account ID of the owner of the security group.

setOwnerId

public void setOwnerId(java.lang.String ownerId)
The AWS account ID of the owner of the security group.

Parameters:
ownerId - The AWS account ID of the owner of the security group.

withOwnerId

public SecurityGroup withOwnerId(java.lang.String ownerId)
The AWS account ID of the owner of the security group.

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

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

getGroupName

public java.lang.String getGroupName()
The name of the security group.

Returns:
The name of the security group.

setGroupName

public void setGroupName(java.lang.String groupName)
The name of the security group.

Parameters:
groupName - The name of the security group.

withGroupName

public SecurityGroup withGroupName(java.lang.String groupName)
The name of the security group.

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

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

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 SecurityGroup 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.

getDescription

public java.lang.String getDescription()
A description of the security group.

Returns:
A description of the security group.

setDescription

public void setDescription(java.lang.String description)
A description of the security group.

Parameters:
description - A description of the security group.

withDescription

public SecurityGroup withDescription(java.lang.String description)
A description of the security group.

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

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

getIpPermissions

public java.util.List<IpPermission> getIpPermissions()
One or more inbound rules associated with the security group.

Returns:
One or more inbound rules associated with the security group.

setIpPermissions

public void setIpPermissions(java.util.Collection<IpPermission> ipPermissions)
One or more inbound rules associated with the security group.

Parameters:
ipPermissions - One or more inbound rules associated with the security group.

withIpPermissions

public SecurityGroup withIpPermissions(IpPermission... ipPermissions)
One or more inbound rules associated with the security group.

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

Parameters:
ipPermissions - One or more inbound rules associated with the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

withIpPermissions

public SecurityGroup withIpPermissions(java.util.Collection<IpPermission> ipPermissions)
One or more inbound rules associated with the security group.

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

Parameters:
ipPermissions - One or more inbound rules associated with the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

getIpPermissionsEgress

public java.util.List<IpPermission> getIpPermissionsEgress()
[EC2-VPC] One or more outbound rules associated with the security group.

Returns:
[EC2-VPC] One or more outbound rules associated with the security group.

setIpPermissionsEgress

public void setIpPermissionsEgress(java.util.Collection<IpPermission> ipPermissionsEgress)
[EC2-VPC] One or more outbound rules associated with the security group.

Parameters:
ipPermissionsEgress - [EC2-VPC] One or more outbound rules associated with the security group.

withIpPermissionsEgress

public SecurityGroup withIpPermissionsEgress(IpPermission... ipPermissionsEgress)
[EC2-VPC] One or more outbound rules associated with the security group.

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

Parameters:
ipPermissionsEgress - [EC2-VPC] One or more outbound rules associated with the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

withIpPermissionsEgress

public SecurityGroup withIpPermissionsEgress(java.util.Collection<IpPermission> ipPermissionsEgress)
[EC2-VPC] One or more outbound rules associated with the security group.

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

Parameters:
ipPermissionsEgress - [EC2-VPC] One or more outbound rules associated with the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

getVpcId

public java.lang.String getVpcId()
[EC2-VPC] The ID of the VPC for the security group.

Returns:
[EC2-VPC] The ID of the VPC for the security group.

setVpcId

public void setVpcId(java.lang.String vpcId)
[EC2-VPC] The ID of the VPC for the security group.

Parameters:
vpcId - [EC2-VPC] The ID of the VPC for the security group.

withVpcId

public SecurityGroup withVpcId(java.lang.String vpcId)
[EC2-VPC] The ID of the VPC for the security group.

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

Parameters:
vpcId - [EC2-VPC] The ID of the VPC for the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

getTags

public java.util.List<Tag> getTags()
Any tags assigned to the security group.

Returns:
Any tags assigned to the security group.

setTags

public void setTags(java.util.Collection<Tag> tags)
Any tags assigned to the security group.

Parameters:
tags - Any tags assigned to the security group.

withTags

public SecurityGroup withTags(Tag... tags)
Any tags assigned to the security group.

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

Parameters:
tags - Any tags assigned to the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

withTags

public SecurityGroup withTags(java.util.Collection<Tag> tags)
Any tags assigned to the security group.

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

Parameters:
tags - Any tags assigned to the security group.
Returns:
A reference to this updated object so that method calls can be chained together.

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.