Class AnnotationTrait.Provider<T extends AnnotationTrait>

java.lang.Object
software.amazon.smithy.model.traits.AbstractTrait.Provider
software.amazon.smithy.model.traits.AnnotationTrait.Provider<T>
All Implemented Interfaces:
TraitService
Direct Known Subclasses:
AddedDefaultTrait.Provider, AwsQueryCompatibleTrait.Provider, AwsQueryTrait.Provider, BoxTrait.Provider, CfnAdditionalIdentifierTrait.Provider, CfnDefaultValueTrait.Provider, CfnExcludePropertyTrait.Provider, ClientEndpointDiscoveryIdTrait.Provider, ClientOptionalTrait.Provider, ControlPlaneTrait.Provider, DataPlaneTrait.Provider, DisableConditionKeyInferenceTrait.Provider, Ec2QueryTrait.Provider, EventHeaderTrait.Provider, EventPayloadTrait.Provider, HostLabelTrait.Provider, HttpBasicAuthTrait.Provider, HttpBearerAuthTrait.Provider, HttpChecksumRequiredTrait.Provider, HttpDigestAuthTrait.Provider, HttpLabelTrait.Provider, HttpPayloadTrait.Provider, HttpQueryParamsTrait.Provider, HttpResponseCodeTrait.Provider, IdempotencyTokenTrait.Provider, IdempotentTrait.Provider, InputTrait.Provider, InternalTrait.Provider, MqttJsonTrait.Provider, NestedPropertiesTrait.Provider, NoReplaceTrait.Provider, NotPropertyTrait.Provider, OptionalAuthTrait.Provider, OutputTrait.Provider, PrivateTrait.Provider, ReadonlyTrait.Provider, RequiredTrait.Provider, RequiresLengthTrait.Provider, S3UnwrappedXmlOutputTrait.Provider, SensitiveTrait.Provider, SparseTrait.Provider, StreamingTrait.Provider, TopicLabelTrait.Provider, UniqueItemsTrait.Provider, UnitTypeTrait.Provider, UnsignedPayloadTrait.Provider, UnstableTrait.Provider, XmlAttributeTrait.Provider, XmlFlattenedTrait.Provider
Enclosing class:
AnnotationTrait

public static class AnnotationTrait.Provider<T extends AnnotationTrait> extends AbstractTrait.Provider
Trait provider that expects a boolean value of true.
  • Constructor Details

    • Provider

      public Provider(ShapeId id, Function<ObjectNode,T> traitFactory)
      Parameters:
      id - ID of the trait being created.
      traitFactory - Factory function used to create the trait.
  • Method Details

    • createTrait

      public T createTrait(ShapeId id, Node value)
      Description copied from interface: TraitService
      Creates the trait from a node value.
      Parameters:
      id - The shape targeted by the trait.
      value - The value of the trait.
      Returns:
      Returns the created trait.