/* * Copyright 2018-2023 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.securityhub.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Criteria for the stateless rule. *
* * @see AWS API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class RuleGroupSourceStatelessRuleMatchAttributes implements Serializable, Cloneable, StructuredPojo { /** ** A list of port ranges to specify the destination ports to inspect for. *
*/ private java.util.List* The destination IP addresses and address ranges to inspect for, in CIDR notation. *
*/ private java.util.List* The protocols to inspect for. *
*/ private java.util.List* A list of port ranges to specify the source ports to inspect for. *
*/ private java.util.List* The source IP addresses and address ranges to inspect for, in CIDR notation. *
*/ private java.util.List* The TCP flags and masks to inspect for. *
*/ private java.util.List* A list of port ranges to specify the destination ports to inspect for. *
* * @return A list of port ranges to specify the destination ports to inspect for. */ public java.util.List* A list of port ranges to specify the destination ports to inspect for. *
* * @param destinationPorts * A list of port ranges to specify the destination ports to inspect for. */ public void setDestinationPorts(java.util.Collection* A list of port ranges to specify the destination ports to inspect for. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setDestinationPorts(java.util.Collection)} or {@link #withDestinationPorts(java.util.Collection)} if you * want to override the existing values. *
* * @param destinationPorts * A list of port ranges to specify the destination ports to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withDestinationPorts(RuleGroupSourceStatelessRuleMatchAttributesDestinationPorts... destinationPorts) { if (this.destinationPorts == null) { setDestinationPorts(new java.util.ArrayList* A list of port ranges to specify the destination ports to inspect for. *
* * @param destinationPorts * A list of port ranges to specify the destination ports to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withDestinationPorts( java.util.Collection* The destination IP addresses and address ranges to inspect for, in CIDR notation. *
* * @return The destination IP addresses and address ranges to inspect for, in CIDR notation. */ public java.util.List* The destination IP addresses and address ranges to inspect for, in CIDR notation. *
* * @param destinations * The destination IP addresses and address ranges to inspect for, in CIDR notation. */ public void setDestinations(java.util.Collection* The destination IP addresses and address ranges to inspect for, in CIDR notation. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setDestinations(java.util.Collection)} or {@link #withDestinations(java.util.Collection)} if you want to * override the existing values. *
* * @param destinations * The destination IP addresses and address ranges to inspect for, in CIDR notation. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withDestinations(RuleGroupSourceStatelessRuleMatchAttributesDestinations... destinations) { if (this.destinations == null) { setDestinations(new java.util.ArrayList* The destination IP addresses and address ranges to inspect for, in CIDR notation. *
* * @param destinations * The destination IP addresses and address ranges to inspect for, in CIDR notation. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withDestinations( java.util.Collection* The protocols to inspect for. *
* * @return The protocols to inspect for. */ public java.util.List* The protocols to inspect for. *
* * @param protocols * The protocols to inspect for. */ public void setProtocols(java.util.Collection* The protocols to inspect for. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setProtocols(java.util.Collection)} or {@link #withProtocols(java.util.Collection)} if you want to * override the existing values. *
* * @param protocols * The protocols to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withProtocols(Integer... protocols) { if (this.protocols == null) { setProtocols(new java.util.ArrayList* The protocols to inspect for. *
* * @param protocols * The protocols to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withProtocols(java.util.Collection* A list of port ranges to specify the source ports to inspect for. *
* * @return A list of port ranges to specify the source ports to inspect for. */ public java.util.List* A list of port ranges to specify the source ports to inspect for. *
* * @param sourcePorts * A list of port ranges to specify the source ports to inspect for. */ public void setSourcePorts(java.util.Collection* A list of port ranges to specify the source ports to inspect for. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setSourcePorts(java.util.Collection)} or {@link #withSourcePorts(java.util.Collection)} if you want to * override the existing values. *
* * @param sourcePorts * A list of port ranges to specify the source ports to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withSourcePorts(RuleGroupSourceStatelessRuleMatchAttributesSourcePorts... sourcePorts) { if (this.sourcePorts == null) { setSourcePorts(new java.util.ArrayList* A list of port ranges to specify the source ports to inspect for. *
* * @param sourcePorts * A list of port ranges to specify the source ports to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withSourcePorts(java.util.Collection* The source IP addresses and address ranges to inspect for, in CIDR notation. *
* * @return The source IP addresses and address ranges to inspect for, in CIDR notation. */ public java.util.List* The source IP addresses and address ranges to inspect for, in CIDR notation. *
* * @param sources * The source IP addresses and address ranges to inspect for, in CIDR notation. */ public void setSources(java.util.Collection* The source IP addresses and address ranges to inspect for, in CIDR notation. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setSources(java.util.Collection)} or {@link #withSources(java.util.Collection)} if you want to override * the existing values. *
* * @param sources * The source IP addresses and address ranges to inspect for, in CIDR notation. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withSources(RuleGroupSourceStatelessRuleMatchAttributesSources... sources) { if (this.sources == null) { setSources(new java.util.ArrayList* The source IP addresses and address ranges to inspect for, in CIDR notation. *
* * @param sources * The source IP addresses and address ranges to inspect for, in CIDR notation. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withSources(java.util.Collection* The TCP flags and masks to inspect for. *
* * @return The TCP flags and masks to inspect for. */ public java.util.List* The TCP flags and masks to inspect for. *
* * @param tcpFlags * The TCP flags and masks to inspect for. */ public void setTcpFlags(java.util.Collection* The TCP flags and masks to inspect for. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setTcpFlags(java.util.Collection)} or {@link #withTcpFlags(java.util.Collection)} if you want to override * the existing values. *
* * @param tcpFlags * The TCP flags and masks to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withTcpFlags(RuleGroupSourceStatelessRuleMatchAttributesTcpFlags... tcpFlags) { if (this.tcpFlags == null) { setTcpFlags(new java.util.ArrayList* The TCP flags and masks to inspect for. *
* * @param tcpFlags * The TCP flags and masks to inspect for. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatelessRuleMatchAttributes withTcpFlags(java.util.Collection