Class CfnResourceTrait

java.lang.Object
software.amazon.smithy.model.traits.AbstractTrait
software.amazon.smithy.aws.cloudformation.traits.CfnResourceTrait
All Implemented Interfaces:
FromSourceLocation, ToNode, ToShapeId, Trait, ToSmithyBuilder<CfnResourceTrait>

public final class CfnResourceTrait extends AbstractTrait implements ToSmithyBuilder<CfnResourceTrait>
Indicates that a Smithy resource is a CloudFormation resource.
  • Field Details

    • ID

      public static final ShapeId ID
  • Method Details

    • getName

      public Optional<String> getName()
      Get the AWS CloudFormation resource name.
      Returns:
      Returns the name.
    • getAdditionalSchemas

      public List<ShapeId> getAdditionalSchemas()
      Get the Smithy structure shape Ids for additional schema properties.
      Returns:
      Returns the additional schema shape Ids.
    • builder

      public static CfnResourceTrait.Builder builder()
    • createNode

      protected Node createNode()
      Description copied from class: AbstractTrait
      The result of toNode is used for hashCodes and equality. Subclasses must implement createNode to turn the trait into a Node. This is then cached for subsequent retrievals.
      Specified by:
      createNode in class AbstractTrait
      Returns:
      Returns the trait as a node.
    • toBuilder

      public SmithyBuilder<CfnResourceTrait> toBuilder()
      Description copied from interface: ToSmithyBuilder
      Take this object and create a builder that contains all of the current property values of this object.
      Specified by:
      toBuilder in interface ToSmithyBuilder<CfnResourceTrait>
      Returns:
      a builder for type T