Package software.amazon.smithy.utils
Interface SmithyBuilder<T>
- Type Parameters:
T
- the type that the builder will build.
- All Known Implementing Classes:
AbstractShapeBuilder
,AbstractTraitBuilder
,ActionResource.Builder
,ActionResources.Builder
,ArnReferenceTrait.Builder
,ArnTrait.Builder
,ArrayNode.Builder
,ArtifactDefinitions.Builder
,AuthDefinitionTrait.Builder
,AuthorizerDefinition.Builder
,AuthorizersTrait.Builder
,AwsArn.Builder
,AwsJson1_0Trait.Builder
,AwsJson1_1Trait.Builder
,AwsProtocolTrait.Builder
,AwsQueryErrorTrait.Builder
,BigDecimalShape.Builder
,BigIntegerShape.Builder
,BlobShape.Builder
,BooleanShape.Builder
,ByteShape.Builder
,CallbackObject.Builder
,CapturedToken.Builder
,CfnResource.Builder
,CfnResourceProperty.Builder
,CfnResourceTrait.Builder
,ClientContextParamDefinition.Builder
,ClientContextParamsTrait.Builder
,ClientDiscoveredEndpointTrait.Builder
,ClientEndpointDiscoveryTrait.Builder
,CognitoUserPoolsTrait.Builder
,CollectionShape.Builder
,Component.Builder
,ComponentsObject.Builder
,Condition.Builder
,ConditionKeyDefinition.Builder
,ConditionKeysTrait.Builder
,ContextParamTrait.Builder
,CorsTrait.Builder
,DefineConditionKeysTrait.Builder
,DeprecatedTrait.Builder
,DocumentShape.Builder
,DoubleShape.Builder
,EffectiveTraitQuery.Builder
,EncodingObject.Builder
,Endpoint.Builder
,EndpointRuleSet.Builder
,EndpointRuleSetTrait.Builder
,EndpointTestCase.Builder
,EndpointTestExpectation.Builder
,EndpointTestOperationInput.Builder
,EndpointTestsTrait.Builder
,EndpointTrait.Builder
,EndpointValue.Builder
,EntityShape.Builder
,EnumDefinition.Builder
,EnumShape.Builder
,EnumTrait.Builder
,EnumValueTrait.Builder
,ExampleObject.Builder
,ExamplesTrait.Builder
,ExamplesTrait.ErrorExample.Builder
,ExamplesTrait.Example.Builder
,ExpectedEndpoint.Builder
,ExternalDocumentation.Builder
,ExternalDocumentationTrait.Builder
,FloatShape.Builder
,FunctionNode.Builder
,Handler.Builder
,HttpApiKeyAuthTrait.Builder
,HttpChecksumTrait.Builder
,HttpMalformedRequestDefinition.Builder
,HttpMalformedRequestTestCase.Builder
,HttpMalformedResponseBodyDefinition.Builder
,HttpMalformedResponseDefinition.Builder
,HttpRequestTestCase.Builder
,HttpResponseTestCase.Builder
,HttpTrait.Builder
,IamActionTrait.Builder
,IamResourceTrait.Builder
,IdRefTrait.Builder
,InfoObject.Builder
,IntegerShape.Builder
,IntegrationResponse.Builder
,IntegrationTrait.Builder
,IntEnumShape.Builder
,JsonSchemaConverter.Builder
,LengthTrait.Builder
,LinkObject.Builder
,ListShape.Builder
,LongShape.Builder
,MappedReservedWords.Builder
,MapShape.Builder
,MavenConfig.Builder
,MavenRepository.Builder
,MediaTypeObject.Builder
,MemberShape.Builder
,MixinTrait.Builder
,MockIntegrationTrait.Builder
,Model.Builder
,ModelSerializer.Builder
,NodeValidationVisitor.Builder
,ObjectNode.Builder
,OpenApi.Builder
,OperationObject.Builder
,OperationShape.Builder
,PaginatedTrait.Builder
,Parameter.Builder
,ParameterObject.Builder
,Parameters.Builder
,Partition.Builder
,PartitionEndpointSpecialCase.Builder
,PartitionOutputs.Builder
,Partitions.Builder
,PartitionSpecialCase.Builder
,PathItem.Builder
,PluginContext.Builder
,ProjectionConfig.Builder
,ProjectionResult.Builder
,Property.Builder
,PropertyTrait.Builder
,ProtocolDefinitionTrait.Builder
,RangeTrait.Builder
,RecommendedTrait.Builder
,ReferencesTrait.Builder
,ReferencesTrait.Reference.Builder
,RegionOverride.Builder
,RegionSpecialCase.Builder
,Remote.Builder
,RequestBodyObject.Builder
,RequestCompressionTrait.Builder
,RequiredActionsTrait.Builder
,ResourceSchema.Builder
,ResourceShape.Builder
,ResponseObject.Builder
,RestJson1Trait.Builder
,RestXmlTrait.Builder
,RetryableTrait.Builder
,RulesComponentBuilder
,Schema.Builder
,SchemaDocument.Builder
,SecurityScheme.Builder
,ServerObject.Builder
,ServiceShape.Builder
,ServiceTrait.Builder
,SetShape.Builder
,ShapeLink.Builder
,ShortShape.Builder
,SigV4Trait.Builder
,SmithyBuildConfig.Builder
,SmithyBuildResult.Builder
,SmithyIdlModelSerializer.Builder
,SmokeTestCase.Builder
,SpecificationExtensionTrait.Builder
,StandardPartitionalEndpointsTrait.Builder
,StandardRegionalEndpointsTrait.Builder
,StaticContextParamDefinition.Builder
,StaticContextParamsTrait.Builder
,StringListTrait.Builder
,StringShape.Builder
,StructureShape.Builder
,SupportedPrincipalTypesTrait.Builder
,SuppressTrait.Builder
,Symbol.Builder
,SymbolDependency.Builder
,SymbolReference.Builder
,SyntheticEnumTrait.Builder
,TagEnabledTrait.Builder
,TaggableApiConfig.Builder
,TaggableTrait.Builder
,Tagging.Builder
,TagObject.Builder
,TagsTrait.Builder
,TimestampShape.Builder
,TraceFile.Builder
,TraceMetadata.Builder
,TracingSymbolProvider.Builder
,TraitDefinition.Builder
,TransformConfig.Builder
,TransformContext.Builder
,UnionShape.Builder
,ValidationEvent.Builder
,WaitableTrait.Builder
,Waiter.Builder
,XmlNamespaceTrait.Builder
,XmlObject.Builder
public interface SmithyBuilder<T>
A mutable object that can be used to create an immutable object of type T.
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Creates an immutable object that is created from the properties that have been set on the builder.static <T> T
requiredState
(String method, T value) Convenience method for ensuring that a value was set on a builder, and if not, throws an IllegalStateException with a useful message.
-
Method Details
-
build
T build()Creates an immutable object that is created from the properties that have been set on the builder.- Returns:
- an instance of T
-
requiredState
Convenience method for ensuring that a value was set on a builder, and if not, throws an IllegalStateException with a useful message.- Type Parameters:
T
- Type of value being checked.- Parameters:
method
- Method that needs to be called to set this value.value
- Value to check.- Returns:
- Returns the value.
-