Class EffectiveTraitQuery
- java.lang.Object
-
- software.amazon.smithy.model.traits.EffectiveTraitQuery
-
- All Implemented Interfaces:
software.amazon.smithy.utils.ToSmithyBuilder<EffectiveTraitQuery>
public final class EffectiveTraitQuery extends java.lang.Object implements software.amazon.smithy.utils.ToSmithyBuilder<EffectiveTraitQuery>
Queries a shape index for effective traits bound to shapes and members.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
EffectiveTraitQuery.Builder
Builds a reusable EffectiveTraitQuery.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static EffectiveTraitQuery.Builder
builder()
Creates a new query builder.boolean
isTraitApplied(ToShapeId shapeId)
Checks if the trait is effectively applied to a shape.EffectiveTraitQuery.Builder
toBuilder()
-
-
-
Method Detail
-
isTraitApplied
public boolean isTraitApplied(ToShapeId shapeId)
Checks if the trait is effectively applied to a shape.- Parameters:
shapeId
- Shape to test.- Returns:
- Returns true if the trait is effectively applied to the shape.
-
builder
public static EffectiveTraitQuery.Builder builder()
Creates a new query builder.- Returns:
- Returns the created builder.
-
toBuilder
public EffectiveTraitQuery.Builder toBuilder()
- Specified by:
toBuilder
in interfacesoftware.amazon.smithy.utils.ToSmithyBuilder<EffectiveTraitQuery>
-
-