All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.securityhub.model.RuleGroupSourceStatefulRulesDetails Maven / Gradle / Ivy

Go to download

The AWS Java SDK for AWS SecurityHub module holds the client classes that are used for communicating with AWS SecurityHub Service

There is a newer version: 1.12.780
Show newest version
/*
 * 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;

/**
 * 

* A Suricata rule specification. *

* * @see AWS API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class RuleGroupSourceStatefulRulesDetails implements Serializable, Cloneable, StructuredPojo { /** *

* Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the stateful * rule criteria. *

*/ private String action; /** *

* The stateful inspection criteria for the rule. *

*/ private RuleGroupSourceStatefulRulesHeaderDetails header; /** *

* Additional options for the rule. *

*/ private java.util.List ruleOptions; /** *

* Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the stateful * rule criteria. *

* * @param action * Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the * stateful rule criteria. */ public void setAction(String action) { this.action = action; } /** *

* Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the stateful * rule criteria. *

* * @return Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the * stateful rule criteria. */ public String getAction() { return this.action; } /** *

* Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the stateful * rule criteria. *

* * @param action * Defines what Network Firewall should do with the packets in a traffic flow when the flow matches the * stateful rule criteria. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatefulRulesDetails withAction(String action) { setAction(action); return this; } /** *

* The stateful inspection criteria for the rule. *

* * @param header * The stateful inspection criteria for the rule. */ public void setHeader(RuleGroupSourceStatefulRulesHeaderDetails header) { this.header = header; } /** *

* The stateful inspection criteria for the rule. *

* * @return The stateful inspection criteria for the rule. */ public RuleGroupSourceStatefulRulesHeaderDetails getHeader() { return this.header; } /** *

* The stateful inspection criteria for the rule. *

* * @param header * The stateful inspection criteria for the rule. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatefulRulesDetails withHeader(RuleGroupSourceStatefulRulesHeaderDetails header) { setHeader(header); return this; } /** *

* Additional options for the rule. *

* * @return Additional options for the rule. */ public java.util.List getRuleOptions() { return ruleOptions; } /** *

* Additional options for the rule. *

* * @param ruleOptions * Additional options for the rule. */ public void setRuleOptions(java.util.Collection ruleOptions) { if (ruleOptions == null) { this.ruleOptions = null; return; } this.ruleOptions = new java.util.ArrayList(ruleOptions); } /** *

* Additional options for the rule. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setRuleOptions(java.util.Collection)} or {@link #withRuleOptions(java.util.Collection)} if you want to * override the existing values. *

* * @param ruleOptions * Additional options for the rule. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatefulRulesDetails withRuleOptions(RuleGroupSourceStatefulRulesOptionsDetails... ruleOptions) { if (this.ruleOptions == null) { setRuleOptions(new java.util.ArrayList(ruleOptions.length)); } for (RuleGroupSourceStatefulRulesOptionsDetails ele : ruleOptions) { this.ruleOptions.add(ele); } return this; } /** *

* Additional options for the rule. *

* * @param ruleOptions * Additional options for the rule. * @return Returns a reference to this object so that method calls can be chained together. */ public RuleGroupSourceStatefulRulesDetails withRuleOptions(java.util.Collection ruleOptions) { setRuleOptions(ruleOptions); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getAction() != null) sb.append("Action: ").append(getAction()).append(","); if (getHeader() != null) sb.append("Header: ").append(getHeader()).append(","); if (getRuleOptions() != null) sb.append("RuleOptions: ").append(getRuleOptions()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof RuleGroupSourceStatefulRulesDetails == false) return false; RuleGroupSourceStatefulRulesDetails other = (RuleGroupSourceStatefulRulesDetails) obj; if (other.getAction() == null ^ this.getAction() == null) return false; if (other.getAction() != null && other.getAction().equals(this.getAction()) == false) return false; if (other.getHeader() == null ^ this.getHeader() == null) return false; if (other.getHeader() != null && other.getHeader().equals(this.getHeader()) == false) return false; if (other.getRuleOptions() == null ^ this.getRuleOptions() == null) return false; if (other.getRuleOptions() != null && other.getRuleOptions().equals(this.getRuleOptions()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAction() == null) ? 0 : getAction().hashCode()); hashCode = prime * hashCode + ((getHeader() == null) ? 0 : getHeader().hashCode()); hashCode = prime * hashCode + ((getRuleOptions() == null) ? 0 : getRuleOptions().hashCode()); return hashCode; } @Override public RuleGroupSourceStatefulRulesDetails clone() { try { return (RuleGroupSourceStatefulRulesDetails) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.securityhub.model.transform.RuleGroupSourceStatefulRulesDetailsMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy