Class EntityShape.Builder<B extends EntityShape.Builder<B,S>,S extends EntityShape>
- java.lang.Object
-
- software.amazon.smithy.model.shapes.AbstractShapeBuilder<B,S>
-
- software.amazon.smithy.model.shapes.EntityShape.Builder<B,S>
-
- Type Parameters:
B
- Concrete builder type.S
- Shape type being created.
- All Implemented Interfaces:
FromSourceLocation
,SmithyBuilder<S>
- Direct Known Subclasses:
ResourceShape.Builder
,ServiceShape.Builder
- Enclosing class:
- EntityShape
public abstract static class EntityShape.Builder<B extends EntityShape.Builder<B,S>,S extends EntityShape> extends AbstractShapeBuilder<B,S>
Builder used to create a Service or Resource shape.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description B
addOperation(java.lang.String id)
B
addOperation(ToShapeId id)
B
addResource(java.lang.String id)
B
addResource(ToShapeId id)
B
clearOperations()
B
clearResources()
B
flattenMixins()
Removes mixins from a shape and flattens them into the shape.B
operations(java.util.Collection<ShapeId> ids)
B
removeOperation(ToShapeId id)
B
removeResource(ToShapeId id)
B
resources(java.util.Collection<ShapeId> ids)
-
Methods inherited from class software.amazon.smithy.model.shapes.AbstractShapeBuilder
addMember, addMixin, addTrait, addTraits, clearMembers, clearMixins, clearTraits, getAllTraits, getId, getMember, getShapeType, getSourceLocation, id, id, mixins, removeMixin, removeTrait, removeTrait, source, source, traits
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface software.amazon.smithy.utils.SmithyBuilder
build
-
-
-
-
Method Detail
-
addOperation
public B addOperation(java.lang.String id)
-
clearOperations
public B clearOperations()
-
addResource
public B addResource(java.lang.String id)
-
clearResources
public B clearResources()
-
flattenMixins
public B flattenMixins()
Description copied from class:AbstractShapeBuilder
Removes 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:
flattenMixins
in classAbstractShapeBuilder<B extends EntityShape.Builder<B,S>,S extends EntityShape>
- Returns:
- Returns the updated builder.
-
-