Hi all,
I was wondering how difficult could be to generate an XML Schema (XSD)
out of a collection of Jackson-annotated POJOs.
I have attempted using jackson-module-jsonSchema for obtaining a JSON
schema in first place, which could be translated somehow into XSD, but
could not figure out how to pass multiple classes to
acceptJsonFormatVisitor:
ObjectMapper m = new ObjectMapper();
SchemaFactoryWrapper visitor = new SchemaFactoryWrapper();
m.acceptJsonFormatVisitor(m.constructType(SimpleBean.class), visitor);
JsonSchema jsonSchema = visitor.finalSchema();
Any idea about this or any alternative approach possibly relying on
jackson-dataformat-xml?
FYI, I've initially started this discussion at [1].
TIA
Regards.
[1]
https://github.com/FasterXML/jackson-dataformat-xml/issues/202
--
Francesco Chicchiriccò
Tirasa - Open Source Excellence
http://www.tirasa.net/
Involved at The Apache Software Foundation:
member, Syncope PMC chair, Cocoon PMC, Olingo PMC,
CXF Committer, OpenJPA Committer, PonyMail PPMC
http://home.apache.org/~ilgrosso/