Package software.amazon.awscdk
Interface PolicyViolatingResource
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
PolicyViolatingResource.Jsii$Proxy
@Generated(value="jsii-pacmak/1.129.0 (build eaca441)",
date="2026-05-13T16:55:01.887Z")
@Stability(Stable)
public interface PolicyViolatingResource
extends software.amazon.jsii.JsiiSerializable
Resource violating a specific rule.
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;
PolicyViolatingResource policyViolatingResource = PolicyViolatingResource.builder()
.locations(List.of("locations"))
// the properties below are optional
.constructPath("constructPath")
.resourceLogicalId("resourceLogicalId")
.templatePath("templatePath")
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forPolicyViolatingResourcestatic final classAn implementation forPolicyViolatingResource -
Method Summary
Modifier and TypeMethodDescriptionbuilder()default StringThe construct path of the violating construct.The locations in the CloudFormation template that pose the violations.default StringThe logical ID of the resource in the CloudFormation template.default StringThe path to the CloudFormation template that contains this resource.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getLocations
The locations in the CloudFormation template that pose the violations. -
getConstructPath
The construct path of the violating construct.Use this for violations that originate from constructs rather than CloudFormation resources (e.g. annotations added via
Annotations.of()orValidations.of()). When provided, the report will use this path directly instead of deriving it from the resource logical ID. Mutually exclusive withresourceLogicalId.Default: - construct path is derived from the resource logical ID
-
getResourceLogicalId
The logical ID of the resource in the CloudFormation template.Required for plugin-sourced violations that operate on CloudFormation templates. Mutually exclusive with
constructPath.Default: - no resource logical ID
-
getTemplatePath
The path to the CloudFormation template that contains this resource.Default: - no template path
-
builder
- Returns:
- a
PolicyViolatingResource.BuilderofPolicyViolatingResource
-