facebook

Generating XML Schema from Hibernate Java Classes

  1. MyEclipse IDE
  2.  > 
  3. Off Topic
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #273131 Reply

    fullerj
    Member

    I have the following process for modeling data:

    1) Create an entity-relationship data model using Erwin
    2) Generate DDL from the model and create MySQL entities
    3) Hibernate Reverse Engineer with MyEclipse to create the Java classes

    The next problem to solve is to be able to handle input from XML data. I would like to be able to generate XML schemas from which data can be provided that can then be mapped to the Java classes created in step 3) above. I have looked at Skaringa which can generate both schemas as well as xml data from the Java classes – i.e., I can instantiate some objects containing test data and generate an xml data file based on the Java classes and their relationships as interpreted by Skaringa. The tool can also generate schemas for the classes although this operation does not seem to be wholly satisfactory, as I don’t get a single schema that matches the xml data file created in the other step.

    In an attempt to get a better schema I have fed the xml data file created by Skaringa into XmlSpy and gotten a single schema for the whole set. However, it does not look correct. XmlSpy does not seem able to create a schema from Java classes directly.

    Does anyone have any experience doing this sort of task? There appear to be numerous options that can take a schema and create or fill Java classes but I have really not found too many options that can automate the process in reverse. Seems as though it would be a very desirable thing to do.

    Thanks.

    John

    #273197 Reply

    Riyad Kalla
    Member

    Moving to OT > Soft Dev

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: Generating XML Schema from Hibernate Java Classes

You must be logged in to post in the forum log in