/* * Copyright 2010-2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). * You may not use this file except in compliance with the License. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ package com.amazonaws.services.ec2.model; import java.io.Serializable; /** *
* Describes a stale security group (a security group that contains stale * rules). *
*/ public class StaleSecurityGroup implements Serializable { /** * The ID of the security group. */ private String groupId; /** * The name of the security group. */ private String groupName; /** * The description of the security group. */ private String description; /** * The ID of the VPC for the security group. */ private String vpcId; /** * Information about the stale inbound rules in the security group. */ private com.amazonaws.internal.ListWithAutoConstructFlag* Returns a reference to this object so that method calls can be chained together. * * @param groupId The ID of the security group. * * @return A reference to this updated object so that method calls can be chained * together. */ public StaleSecurityGroup withGroupId(String groupId) { this.groupId = groupId; return this; } /** * The name of the security group. * * @return The name of the security group. */ public String getGroupName() { return groupName; } /** * The name of the security group. * * @param groupName The name of the security group. */ public void setGroupName(String groupName) { this.groupName = groupName; } /** * The name of the security group. *
* Returns a reference to this object so that method calls can be chained together. * * @param groupName The name of the security group. * * @return A reference to this updated object so that method calls can be chained * together. */ public StaleSecurityGroup withGroupName(String groupName) { this.groupName = groupName; return this; } /** * The description of the security group. * * @return The description of the security group. */ public String getDescription() { return description; } /** * The description of the security group. * * @param description The description of the security group. */ public void setDescription(String description) { this.description = description; } /** * The description of the security group. *
* Returns a reference to this object so that method calls can be chained together. * * @param description The description of the security group. * * @return A reference to this updated object so that method calls can be chained * together. */ public StaleSecurityGroup withDescription(String description) { this.description = description; return this; } /** * The ID of the VPC for the security group. * * @return The ID of the VPC for the security group. */ public String getVpcId() { return vpcId; } /** * The ID of the VPC for the security group. * * @param vpcId The ID of the VPC for the security group. */ public void setVpcId(String vpcId) { this.vpcId = vpcId; } /** * The ID of the VPC for the security group. *
* Returns a reference to this object so that method calls can be chained together.
*
* @param vpcId The ID of the VPC for the security group.
*
* @return A reference to this updated object so that method calls can be chained
* together.
*/
public StaleSecurityGroup withVpcId(String vpcId) {
this.vpcId = vpcId;
return this;
}
/**
* Information about the stale inbound rules in the security group.
*
* @return Information about the stale inbound rules in the security group.
*/
public java.util.List
* Returns a reference to this object so that method calls can be chained together.
*
* @param staleIpPermissions Information about the stale inbound rules in the security group.
*
* @return A reference to this updated object so that method calls can be chained
* together.
*/
public StaleSecurityGroup withStaleIpPermissions(StaleIpPermission... staleIpPermissions) {
if (getStaleIpPermissions() == null) setStaleIpPermissions(new java.util.ArrayList
* Returns a reference to this object so that method calls can be chained together.
*
* @param staleIpPermissions Information about the stale inbound rules in the security group.
*
* @return A reference to this updated object so that method calls can be chained
* together.
*/
public StaleSecurityGroup withStaleIpPermissions(java.util.Collection
* Returns a reference to this object so that method calls can be chained together.
*
* @param staleIpPermissionsEgress Information about the stale outbound rules in the security group.
*
* @return A reference to this updated object so that method calls can be chained
* together.
*/
public StaleSecurityGroup withStaleIpPermissionsEgress(StaleIpPermission... staleIpPermissionsEgress) {
if (getStaleIpPermissionsEgress() == null) setStaleIpPermissionsEgress(new java.util.ArrayList
* Returns a reference to this object so that method calls can be chained together.
*
* @param staleIpPermissionsEgress Information about the stale outbound rules in the security group.
*
* @return A reference to this updated object so that method calls can be chained
* together.
*/
public StaleSecurityGroup withStaleIpPermissionsEgress(java.util.Collection