Class CfnRelatedItem

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, IRelatedItemRef, IEnvironmentAware, ITaggableV2, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.140.0 (build 79fd58c)", date="2026-09-30T11:04:46.824Z") @Stability(Stable) public class CfnRelatedItem extends CfnResource implements IInspectable, IRelatedItemRef, ITaggableV2
Resource Type definition for AWS::Cases::RelatedItem.

Creates a related item (comments) and associates it with a case.

Example:

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 import software.amazon.awscdk.services.cases.*;
 CfnRelatedItem cfnRelatedItem = CfnRelatedItem.Builder.create(this, "MyCfnRelatedItem")
         .caseId("caseId")
         .content(RelatedItemContentProperty.builder()
                 .comment(CommentContentProperty.builder()
                         .body("body")
                         .contentType("contentType")
                         .build())
                 .build())
         .domainId("domainId")
         .type("type")
         // the properties below are optional
         .tags(List.of(CfnTag.builder()
                 .key("key")
                 .value("value")
                 .build()))
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnRelatedItem

      protected CfnRelatedItem(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnRelatedItem

      protected CfnRelatedItem(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnRelatedItem

      @Stability(Stable) public CfnRelatedItem(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnRelatedItemProps props)
      Create a new AWS::Cases::RelatedItem.

      Parameters:
      scope - Scope in which this resource is defined. This parameter is required.
      id - Construct identifier for this resource (unique in its scope). This parameter is required.
      props - Resource properties. This parameter is required.
  • Method Details

    • arnForRelatedItem

      @Stability(Stable) @NotNull public static String arnForRelatedItem(@NotNull IRelatedItemRef resource)
      Parameters:
      resource - This parameter is required.
    • isCfnRelatedItem

      @Stability(Stable) @NotNull public static Boolean isCfnRelatedItem(@NotNull Object x)
      Checks whether the given object is a CfnRelatedItem.

      Parameters:
      x - This parameter is required.
    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      Parameters:
      inspector - tree inspector to collect and process attributes. This parameter is required.
    • renderProperties

      @Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
      Overrides:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrRelatedItemArn

      @Stability(Stable) @NotNull public String getAttrRelatedItemArn()
      The Amazon Resource Name (ARN) of the related item.
    • getAttrRelatedItemId

      @Stability(Stable) @NotNull public String getAttrRelatedItemId()
      The unique identifier of the related item.
    • getCdkTagManager

      @Stability(Stable) @NotNull public TagManager getCdkTagManager()
      Tag Manager which manages the tags for this resource.
      Specified by:
      getCdkTagManager in interface ITaggableV2
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getCfnPropertyNames

      @Stability(Stable) @NotNull protected Map<String,String> getCfnPropertyNames()
      Overrides:
      getCfnPropertyNames in class CfnResource
    • getRelatedItemRef

      @Stability(Stable) @NotNull public RelatedItemReference getRelatedItemRef()
      A reference to a RelatedItem resource.
      Specified by:
      getRelatedItemRef in interface IRelatedItemRef
    • getCaseId

      @Stability(Stable) @NotNull public String getCaseId()
      A unique identifier of the case.
    • setCaseId

      @Stability(Stable) public void setCaseId(@NotNull String value)
      A unique identifier of the case.
    • getContent

      @Stability(Stable) @NotNull public Object getContent()
      Represents the content of a related item.

      Returns union: either IResolvable or CfnRelatedItem.RelatedItemContentProperty

    • setContent

      @Stability(Stable) public void setContent(@NotNull IResolvable value)
      Represents the content of a related item.
    • setContent

      @Stability(Stable) public void setContent(@NotNull CfnRelatedItem.RelatedItemContentProperty value)
      Represents the content of a related item.
    • getDomainId

      @Stability(Stable) @NotNull public String getDomainId()
      The unique identifier of the Cases domain.
    • setDomainId

      @Stability(Stable) public void setDomainId(@NotNull String value)
      The unique identifier of the Cases domain.
    • getType

      @Stability(Stable) @NotNull public String getType()
      The type of a related item.
    • setType

      @Stability(Stable) public void setType(@NotNull String value)
      The type of a related item.
    • getTags

      @Stability(Stable) @Nullable public List<CfnTag> getTags()
      A list of tags on the related item.
    • setTags

      @Stability(Stable) public void setTags(@Nullable List<CfnTag> value)
      A list of tags on the related item.