How to create schema suitable for JAXB?
Posted on 2003-11-13
I have Java objects containing data, that I want to Marshal/Unmarshal, to and from XML files using JAXB. How would I go about creating schema(s) so I can then generate the "binding" classes from the schema? My knowledge of XML and schema is very limited.
Note the JAXB tutorial says: "Representing XML content as Java objects involves two kinds of mappings: binding XML names to Java identifiers, and representing XML schemas as sets of Java classes." Then it also says: "XML schema languages use XML names to label schema components, however this set of strings is much larger than the set of valid Java class, method, and constant identifiers. "
Therefore, How does one know how to write proper schema in the first place???
Are there any tools for generating proper schemas for the JAXB???