Class StringSchema
java.lang.Object
com.fasterxml.jackson.module.jsonSchema.jakarta.JsonSchema
com.fasterxml.jackson.module.jsonSchema.jakarta.types.SimpleTypeSchema
com.fasterxml.jackson.module.jsonSchema.jakarta.types.ValueTypeSchema
com.fasterxml.jackson.module.jsonSchema.jakarta.types.StringSchema
This represents a
JsonSchema as a String-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Integerthis defines the maximum length of the string.private Integerthis defines the minimum length of the string.private Stringthis provides a regular expression that a string instance MUST match in order to be valid.Fields inherited from class ValueTypeSchema
enums, formatFields inherited from class SimpleTypeSchema
defaultdefault, links, pathStart, title -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected boolean_equals(StringSchema that) Attempt to return this JsonSchema as aStringSchemabooleancom.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatTypesgetType()booleandetermine if this JsonSchema is anStringSchema.voidsetMaxLength(Integer maxLength) voidsetMinLength(Integer minLength) voidsetPattern(String pattern) Methods inherited from class ValueTypeSchema
_equals, asValueSchemaSchema, asValueTypeSchema, getEnums, getFormat, isValueTypeSchema, setEnums, setFormatMethods inherited from class SimpleTypeSchema
_equals, asSimpleTypeSchema, getDefault, getLinks, getPathStart, getTitle, isSimpleTypeSchema, setDefault, setLinks, setPathStart, setTitleMethods inherited from class JsonSchema
_equals, arraysEqual, asAnySchema, asArraySchema, asBooleanSchema, asContainerSchema, asContainerTypeSchema, asIntegerSchema, asNullSchema, asNumberSchema, asObjectSchema, asUnionTypeSchema, enrichWithBeanProperty, equals, get$ref, get$schema, getDescription, getDisallow, getExtends, getId, getReadonly, getRequired, isAnySchema, isArraySchema, isBooleanSchema, isContainerTypeSchema, isIntegerSchema, isNullSchema, isNumberSchema, isObjectSchema, isUnionTypeSchema, minimalForFormat, set$ref, set$schema, setDescription, setDisallow, setExtends, setId, setReadonly, setRequired
-
Field Details
-
maxLength
this defines the maximum length of the string. -
minLength
this defines the minimum length of the string. -
pattern
this provides a regular expression that a string instance MUST match in order to be valid. Regular expressions SHOULD follow the regular expression specification from ECMA 262/Perl 5
-
-
Constructor Details
-
StringSchema
public StringSchema()
-
-
Method Details
-
asStringSchema
Description copied from class:JsonSchemaAttempt to return this JsonSchema as aStringSchema- Overrides:
asStringSchemain classJsonSchema- Returns:
- this as a StringSchema if possible, or null otherwise
-
getMaxLength
-
getMinLength
-
getPattern
-
getType
public com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatTypes getType()- Specified by:
getTypein classJsonSchema
-
isStringSchema
public boolean isStringSchema()Description copied from class:JsonSchemadetermine if this JsonSchema is anStringSchema.- Overrides:
isStringSchemain classJsonSchema- Returns:
- true if this JsonSchema is an StringSchema, false otherwise
-
setMaxLength
-
setMinLength
-
setPattern
-
equals
- Overrides:
equalsin classValueTypeSchema
-
_equals
-