Class JsonSchema.JsonSchemaProperty
java.lang.Object
org.springframework.data.rest.webmvc.json.JsonSchema.JsonSchemaProperty
- Direct Known Subclasses:
JsonSchema.EnumProperty
- Enclosing class:
- JsonSchema
A JSON Schema property
- Since:
- 2.3
- Author:
- Oliver Gierke
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionTurns the currentJsonSchema.JsonSchemaProperty
into an association.getName()
getTitle()
boolean
with
(org.springframework.data.util.TypeInformation<?> type) Configures theJsonSchema.JsonSchemaProperty
to reflect the given type.withFormat
(JsonSchemaFormat format) Configures the givenJsonSchemaFormat
to be exposed on the currentJsonSchema.JsonSchemaProperty
.withPattern
(Pattern pattern) Configures theJsonSchema.JsonSchemaProperty
to require the givenPattern
.protected JsonSchema.JsonSchemaProperty
Configures theJsonSchema.JsonSchemaProperty
to require the given regular expression as pattern.Configures theJsonSchema.JsonSchemaProperty
to reflect the given type.
-
Field Details
-
description
-
type
-
format
-
pattern
-
uniqueItems
-
reference
-
items
-
-
Method Details
-
withType
Configures theJsonSchema.JsonSchemaProperty
to reflect the given type.- Parameters:
type
- must not be null.- Returns:
-
with
Configures theJsonSchema.JsonSchemaProperty
to reflect the given type.- Parameters:
type
- must not be null.- Returns:
-
withFormat
Configures the givenJsonSchemaFormat
to be exposed on the currentJsonSchema.JsonSchemaProperty
.- Parameters:
format
- must not be null.- Returns:
-
withRegex
Configures theJsonSchema.JsonSchemaProperty
to require the given regular expression as pattern.- Parameters:
regex
- must not be null.- Returns:
-
withPattern
Configures theJsonSchema.JsonSchemaProperty
to require the givenPattern
.- Parameters:
pattern
- must not be null.- Returns:
-
asAssociation
Turns the currentJsonSchema.JsonSchemaProperty
into an association.- Returns:
-
getName
-
getTitle
-
isReadOnly
public boolean isReadOnly() -
withReadOnly
-