Is there a tool to generate a JSON schema from an XML schema through Java?

Harish Raj picture Harish Raj · Oct 13, 2011 · Viewed 27.3k times · Source

Is anyone aware of a tool or approach from which we can generate a JSON schema from XML schema or XML schema from JSON schema by Java?

Answer

sbridges picture sbridges · Oct 30, 2011

It isn't very elegant, but jackson can generate json schema from a java class . So you could take your xml schema, generate java classes from it with jaxb annotations, then generate the json schema from that as jackson supports jaxb annotations.