/* * 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.fms.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.protocol.StructuredPojo; import com.amazonaws.protocol.ProtocolMarshaller; /** *
* Details of the resource that is not protected by the policy. *
* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ComplianceViolator implements Serializable, Cloneable, StructuredPojo { /** ** The resource ID. *
*/ private String resourceId; /** ** The reason that the resource is not protected by the policy. *
*/ private String violationReason; /** *
* The resource type. This is in the format shown in the Amazon
* Web Services Resource Types Reference. For example: AWS::ElasticLoadBalancingV2::LoadBalancer
,
* AWS::CloudFront::Distribution
, or AWS::NetworkFirewall::FirewallPolicy
.
*
* Metadata about the resource that doesn't comply with the policy scope. *
*/ private java.util.Map* The resource ID. *
* * @param resourceId * The resource ID. */ public void setResourceId(String resourceId) { this.resourceId = resourceId; } /** ** The resource ID. *
* * @return The resource ID. */ public String getResourceId() { return this.resourceId; } /** ** The resource ID. *
* * @param resourceId * The resource ID. * @return Returns a reference to this object so that method calls can be chained together. */ public ComplianceViolator withResourceId(String resourceId) { setResourceId(resourceId); return this; } /** ** The reason that the resource is not protected by the policy. *
* * @param violationReason * The reason that the resource is not protected by the policy. * @see ViolationReason */ public void setViolationReason(String violationReason) { this.violationReason = violationReason; } /** ** The reason that the resource is not protected by the policy. *
* * @return The reason that the resource is not protected by the policy. * @see ViolationReason */ public String getViolationReason() { return this.violationReason; } /** ** The reason that the resource is not protected by the policy. *
* * @param violationReason * The reason that the resource is not protected by the policy. * @return Returns a reference to this object so that method calls can be chained together. * @see ViolationReason */ public ComplianceViolator withViolationReason(String violationReason) { setViolationReason(violationReason); return this; } /** ** The reason that the resource is not protected by the policy. *
* * @param violationReason * The reason that the resource is not protected by the policy. * @return Returns a reference to this object so that method calls can be chained together. * @see ViolationReason */ public ComplianceViolator withViolationReason(ViolationReason violationReason) { this.violationReason = violationReason.toString(); return this; } /** *
* The resource type. This is in the format shown in the Amazon
* Web Services Resource Types Reference. For example: AWS::ElasticLoadBalancingV2::LoadBalancer
,
* AWS::CloudFront::Distribution
, or AWS::NetworkFirewall::FirewallPolicy
.
*
AWS::ElasticLoadBalancingV2::LoadBalancer
, AWS::CloudFront::Distribution
, or
* AWS::NetworkFirewall::FirewallPolicy
.
*/
public void setResourceType(String resourceType) {
this.resourceType = resourceType;
}
/**
*
* The resource type. This is in the format shown in the Amazon
* Web Services Resource Types Reference. For example: AWS::ElasticLoadBalancingV2::LoadBalancer
,
* AWS::CloudFront::Distribution
, or AWS::NetworkFirewall::FirewallPolicy
.
*
AWS::ElasticLoadBalancingV2::LoadBalancer
, AWS::CloudFront::Distribution
, or
* AWS::NetworkFirewall::FirewallPolicy
.
*/
public String getResourceType() {
return this.resourceType;
}
/**
*
* The resource type. This is in the format shown in the Amazon
* Web Services Resource Types Reference. For example: AWS::ElasticLoadBalancingV2::LoadBalancer
,
* AWS::CloudFront::Distribution
, or AWS::NetworkFirewall::FirewallPolicy
.
*
AWS::ElasticLoadBalancingV2::LoadBalancer
, AWS::CloudFront::Distribution
, or
* AWS::NetworkFirewall::FirewallPolicy
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ComplianceViolator withResourceType(String resourceType) {
setResourceType(resourceType);
return this;
}
/**
* * Metadata about the resource that doesn't comply with the policy scope. *
* * @return Metadata about the resource that doesn't comply with the policy scope. */ public java.util.Map* Metadata about the resource that doesn't comply with the policy scope. *
* * @param metadata * Metadata about the resource that doesn't comply with the policy scope. */ public void setMetadata(java.util.Map* Metadata about the resource that doesn't comply with the policy scope. *
* * @param metadata * Metadata about the resource that doesn't comply with the policy scope. * @return Returns a reference to this object so that method calls can be chained together. */ public ComplianceViolator withMetadata(java.util.Map