Class UserIdGroupPair
- java.lang.Object
-
- com.amazonaws.services.ec2.model.UserIdGroupPair
-
- All Implemented Interfaces:
Serializable
,Cloneable
public class UserIdGroupPair extends Object implements Serializable, Cloneable
Describes a security group and AWS account ID pair.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description UserIdGroupPair()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UserIdGroupPair
clone()
boolean
equals(Object obj)
String
getGroupId()
The ID of the security group.String
getGroupName()
The name of the security group.String
getPeeringStatus()
The status of a VPC peering connection, if applicable.String
getUserId()
The ID of an AWS account.String
getVpcId()
The ID of the VPC for the referenced security group, if applicable.String
getVpcPeeringConnectionId()
The ID of the VPC peering connection, if applicable.int
hashCode()
void
setGroupId(String groupId)
The ID of the security group.void
setGroupName(String groupName)
The name of the security group.void
setPeeringStatus(String peeringStatus)
The status of a VPC peering connection, if applicable.void
setUserId(String userId)
The ID of an AWS account.void
setVpcId(String vpcId)
The ID of the VPC for the referenced security group, if applicable.void
setVpcPeeringConnectionId(String vpcPeeringConnectionId)
The ID of the VPC peering connection, if applicable.String
toString()
Returns a string representation of this object; useful for testing and debugging.UserIdGroupPair
withGroupId(String groupId)
The ID of the security group.UserIdGroupPair
withGroupName(String groupName)
The name of the security group.UserIdGroupPair
withPeeringStatus(String peeringStatus)
The status of a VPC peering connection, if applicable.UserIdGroupPair
withUserId(String userId)
The ID of an AWS account.UserIdGroupPair
withVpcId(String vpcId)
The ID of the VPC for the referenced security group, if applicable.UserIdGroupPair
withVpcPeeringConnectionId(String vpcPeeringConnectionId)
The ID of the VPC peering connection, if applicable.
-
-
-
Method Detail
-
setUserId
public void setUserId(String userId)
The ID of an AWS account. For a referenced security group in another VPC, the account ID of the referenced security group is returned.
[EC2-Classic] Required when adding or removing rules that reference a security group in another AWS account.
- Parameters:
userId
- The ID of an AWS account. For a referenced security group in another VPC, the account ID of the referenced security group is returned.[EC2-Classic] Required when adding or removing rules that reference a security group in another AWS account.
-
getUserId
public String getUserId()
The ID of an AWS account. For a referenced security group in another VPC, the account ID of the referenced security group is returned.
[EC2-Classic] Required when adding or removing rules that reference a security group in another AWS account.
- Returns:
- The ID of an AWS account. For a referenced security group in
another VPC, the account ID of the referenced security group is
returned.
[EC2-Classic] Required when adding or removing rules that reference a security group in another AWS account.
-
withUserId
public UserIdGroupPair withUserId(String userId)
The ID of an AWS account. For a referenced security group in another VPC, the account ID of the referenced security group is returned.
[EC2-Classic] Required when adding or removing rules that reference a security group in another AWS account.
- Parameters:
userId
- The ID of an AWS account. For a referenced security group in another VPC, the account ID of the referenced security group is returned.[EC2-Classic] Required when adding or removing rules that reference a security group in another AWS account.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setGroupName
public void setGroupName(String groupName)
The name of the security group. In a request, use this parameter for a security group in EC2-Classic or a default VPC only. For a security group in a nondefault VPC, use the security group ID.
- Parameters:
groupName
- The name of the security group. In a request, use this parameter for a security group in EC2-Classic or a default VPC only. For a security group in a nondefault VPC, use the security group ID.
-
getGroupName
public String getGroupName()
The name of the security group. In a request, use this parameter for a security group in EC2-Classic or a default VPC only. For a security group in a nondefault VPC, use the security group ID.
- Returns:
- The name of the security group. In a request, use this parameter for a security group in EC2-Classic or a default VPC only. For a security group in a nondefault VPC, use the security group ID.
-
withGroupName
public UserIdGroupPair withGroupName(String groupName)
The name of the security group. In a request, use this parameter for a security group in EC2-Classic or a default VPC only. For a security group in a nondefault VPC, use the security group ID.
- Parameters:
groupName
- The name of the security group. In a request, use this parameter for a security group in EC2-Classic or a default VPC only. For a security group in a nondefault VPC, use the security group ID.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setGroupId
public void setGroupId(String groupId)
The ID of the security group.
- Parameters:
groupId
- The ID of the security group.
-
getGroupId
public String getGroupId()
The ID of the security group.
- Returns:
- The ID of the security group.
-
withGroupId
public UserIdGroupPair withGroupId(String groupId)
The ID of the security group.
- Parameters:
groupId
- The ID of the security group.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setVpcId
public void setVpcId(String vpcId)
The ID of the VPC for the referenced security group, if applicable.
- Parameters:
vpcId
- The ID of the VPC for the referenced security group, if applicable.
-
getVpcId
public String getVpcId()
The ID of the VPC for the referenced security group, if applicable.
- Returns:
- The ID of the VPC for the referenced security group, if applicable.
-
withVpcId
public UserIdGroupPair withVpcId(String vpcId)
The ID of the VPC for the referenced security group, if applicable.
- Parameters:
vpcId
- The ID of the VPC for the referenced security group, if applicable.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setVpcPeeringConnectionId
public void setVpcPeeringConnectionId(String vpcPeeringConnectionId)
The ID of the VPC peering connection, if applicable.
- Parameters:
vpcPeeringConnectionId
- The ID of the VPC peering connection, if applicable.
-
getVpcPeeringConnectionId
public String getVpcPeeringConnectionId()
The ID of the VPC peering connection, if applicable.
- Returns:
- The ID of the VPC peering connection, if applicable.
-
withVpcPeeringConnectionId
public UserIdGroupPair withVpcPeeringConnectionId(String vpcPeeringConnectionId)
The ID of the VPC peering connection, if applicable.
- Parameters:
vpcPeeringConnectionId
- The ID of the VPC peering connection, if applicable.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setPeeringStatus
public void setPeeringStatus(String peeringStatus)
The status of a VPC peering connection, if applicable.
- Parameters:
peeringStatus
- The status of a VPC peering connection, if applicable.
-
getPeeringStatus
public String getPeeringStatus()
The status of a VPC peering connection, if applicable.
- Returns:
- The status of a VPC peering connection, if applicable.
-
withPeeringStatus
public UserIdGroupPair withPeeringStatus(String peeringStatus)
The status of a VPC peering connection, if applicable.
- Parameters:
peeringStatus
- The status of a VPC peering connection, if applicable.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
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 UserIdGroupPair clone()
-
-