Class OperationShape.Builder
java.lang.Object
software.amazon.smithy.model.shapes.AbstractShapeBuilder<OperationShape.Builder,OperationShape>
 
software.amazon.smithy.model.shapes.OperationShape.Builder
- All Implemented Interfaces:
- FromSourceLocation,- SmithyBuilder<OperationShape>
- Enclosing class:
- OperationShape
public static final class OperationShape.Builder
extends AbstractShapeBuilder<OperationShape.Builder,OperationShape> 
Builder used to create a 
OperationShape.- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionAdds an error to the operation.Adds an error to the operation.addErrors(Collection<ShapeId> errorShapeIds) Adds an each of the errors to the operation.build()Creates an immutable object that is created from the properties that have been set on the builder.Removes all errors.errors(Collection<ShapeId> errorShapeIds) Sets and replaces the errors of the operation.Removes mixins from a shape and flattens them into the shape.Gets the type of shape being built.Sets the input shape ID of the operation.Sets the output shape ID of the operation.removeError(ToShapeId errorShapeId) Removes an error by Shape ID.Methods inherited from class software.amazon.smithy.model.shapes.AbstractShapeBuilderaddMember, addMixin, addTrait, addTraits, clearMembers, clearMixins, clearTraits, getAllTraits, getId, getMember, getSourceLocation, id, id, mixins, removeMixin, removeTrait, removeTrait, source, source, traits
- 
Constructor Details- 
Builderpublic Builder()
 
- 
- 
Method Details- 
getShapeTypeDescription copied from class:AbstractShapeBuilderGets the type of shape being built.- Specified by:
- getShapeTypein class- AbstractShapeBuilder<OperationShape.Builder,- OperationShape> 
- Returns:
- Returns the shape type.
 
- 
inputSets the input shape ID of the operation.- Parameters:
- inputShape- Shape ID that MUST reference a structure.
- Returns:
- Returns the builder.
 
- 
outputSets the output shape ID of the operation.- Parameters:
- outputShape- Shape ID that MUST reference a structure.
- Returns:
- Returns the builder.
 
- 
errorsSets and replaces the errors of the operation.- Parameters:
- errorShapeIds- Error shape IDs to set.
- Returns:
- Returns the builder.
 
- 
addErrorAdds an error to the operation.- Parameters:
- errorShapeId- Error shape ID to add.
- Returns:
- Returns the builder.
 
- 
addErrorAdds an error to the operation.- Parameters:
- errorShapeId- Error shape ID to add.
- Returns:
- Returns the builder.
- Throws:
- ShapeIdSyntaxException- if the shape ID is invalid.
 
- 
addErrorsAdds an each of the errors to the operation.- Parameters:
- errorShapeIds- Error shape IDs to add.
- Returns:
- Returns the builder.
 
- 
removeErrorRemoves an error by Shape ID.- Parameters:
- errorShapeId- Error shape ID to remove.
- Returns:
- Returns the builder.
 
- 
clearErrorsRemoves all errors.- Returns:
- Returns the builder.
 
- 
buildDescription copied from interface:SmithyBuilderCreates an immutable object that is created from the properties that have been set on the builder.- Returns:
- an instance of T
 
- 
flattenMixinsDescription copied from class:AbstractShapeBuilderRemoves mixins from a shape and flattens them into the shape.Flattening a mixin into a shape copies the traits and members of a mixin onto the shape, effectively resulting in the same shape but with no trace of the mixin relationship. - Overrides:
- flattenMixinsin class- AbstractShapeBuilder<OperationShape.Builder,- OperationShape> 
- Returns:
- Returns the updated builder.
 
 
-