Class PatternTrait
java.lang.Object
software.amazon.smithy.model.traits.AbstractTrait
software.amazon.smithy.model.traits.StringTrait
software.amazon.smithy.model.traits.PatternTrait
- All Implemented Interfaces:
FromSourceLocation,ToNode,ToShapeId,Trait
Restricts string values to a specified regular expression.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPatternTrait(String value) PatternTrait(String value, SourceLocation sourceLocation) -
Method Summary
Methods inherited from class software.amazon.smithy.model.traits.StringTrait
createNode, getValueMethods inherited from class software.amazon.smithy.model.traits.AbstractTrait
equals, getSourceLocation, hashCode, setNodeCache, toNode, toShapeId, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface software.amazon.smithy.model.traits.Trait
isSynthetic
-
Field Details
-
ID
-
-
Constructor Details
-
PatternTrait
-
PatternTrait
-
-
Method Details
-
getPattern
Gets the regex pattern.- Returns:
- returns compiled regular expression.
-