-
I'm trying to validate json against our json schema. According to the spec for which the schema is created, the time value must be "HH:mm". In the schema this is specified for that property in Snippet of schema of property:
Using jsonschema2pojo this create a Java property with the correct type and can successfully be serialised and deserialised. I'm looking at creating a custom |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I found a solution by creating a custom class
and using the
Since the Now my |
Beta Was this translation helpful? Give feedback.
I found a solution by creating a custom class
CustomTimePatternFormat
, extendingTimeFormat
, and implementing theFormat
methodand using the
formatValidator
to get access to other properties of the schema viaSince the
JsonSchema.getNode
method is protected, I had to place my custom class in thecom.networknt.schema
package.Now my
CustomTimePatternFormat
class validates the value …