-
| 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 theFormatmethodand using the
formatValidatorto get access to other properties of the schema viaSince the
JsonSchema.getNodemethod is protected, I had to place my custom class in thecom.networknt.schemapackage.Now my
CustomTimePatternFormatclass validates the value …