/* * 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; /** *
* Provides information about the threat detected in a security finding and the file paths that were affected by the * threat. *
* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class Threat implements Serializable, Cloneable, StructuredPojo { /** ** The name of the threat. *
*/ private String name; /** ** The severity of the threat. *
*/ private String severity; /** ** This total number of items in which the threat has been detected. *
*/ private Integer itemCount; /** ** Provides information about the file paths that were affected by the threat. *
*/ private java.util.List* The name of the threat. *
* * @param name * The name of the threat. */ public void setName(String name) { this.name = name; } /** ** The name of the threat. *
* * @return The name of the threat. */ public String getName() { return this.name; } /** ** The name of the threat. *
* * @param name * The name of the threat. * @return Returns a reference to this object so that method calls can be chained together. */ public Threat withName(String name) { setName(name); return this; } /** ** The severity of the threat. *
* * @param severity * The severity of the threat. */ public void setSeverity(String severity) { this.severity = severity; } /** ** The severity of the threat. *
* * @return The severity of the threat. */ public String getSeverity() { return this.severity; } /** ** The severity of the threat. *
* * @param severity * The severity of the threat. * @return Returns a reference to this object so that method calls can be chained together. */ public Threat withSeverity(String severity) { setSeverity(severity); return this; } /** ** This total number of items in which the threat has been detected. *
* * @param itemCount * This total number of items in which the threat has been detected. */ public void setItemCount(Integer itemCount) { this.itemCount = itemCount; } /** ** This total number of items in which the threat has been detected. *
* * @return This total number of items in which the threat has been detected. */ public Integer getItemCount() { return this.itemCount; } /** ** This total number of items in which the threat has been detected. *
* * @param itemCount * This total number of items in which the threat has been detected. * @return Returns a reference to this object so that method calls can be chained together. */ public Threat withItemCount(Integer itemCount) { setItemCount(itemCount); return this; } /** ** Provides information about the file paths that were affected by the threat. *
* * @return Provides information about the file paths that were affected by the threat. */ public java.util.List* Provides information about the file paths that were affected by the threat. *
* * @param filePaths * Provides information about the file paths that were affected by the threat. */ public void setFilePaths(java.util.Collection* Provides information about the file paths that were affected by the threat. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setFilePaths(java.util.Collection)} or {@link #withFilePaths(java.util.Collection)} if you want to * override the existing values. *
* * @param filePaths * Provides information about the file paths that were affected by the threat. * @return Returns a reference to this object so that method calls can be chained together. */ public Threat withFilePaths(FilePaths... filePaths) { if (this.filePaths == null) { setFilePaths(new java.util.ArrayList* Provides information about the file paths that were affected by the threat. *
* * @param filePaths * Provides information about the file paths that were affected by the threat. * @return Returns a reference to this object so that method calls can be chained together. */ public Threat withFilePaths(java.util.Collection