File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes XML and Related Technologies and the fly likes Generating XSD Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "Generating XSD" Watch "Generating XSD" New topic
Author

Generating XSD

Luke Murphy
Ranch Hand

Joined: May 12, 2010
Posts: 300
Hi,
Suppose you have your domain model defined in XML.
You need to generate XSDs so that you can use representations of your domain model in webservices.

You have two choices:

1. Use something like XLST.
2. Use a scripting language which looks at your XMLs and generates your XSDs?

Questions:
1. What limiations are there using XLST? Is there any fancy logic you will not be able to do using it?
2. If you have to use a scripting language to generate the XSDs what would be a good choice?

Thanks.
Jimmy Clark
Ranch Hand

Joined: Apr 16, 2008
Posts: 2187
You can certainly define the "data" portion of your domain/business model with an XML-based language.

How will you excecute domain/business logic with this data?

1. What limiations are there using XLST? Is there any fancy logic you will not be able to do using it?
2. If you have to use a scripting language to generate the XSDs what would be a good choice?


XSLT is a non-object-oriented programming language. There will be limitations when attempting to implement certains types of logic.

You can create XML schemas with a Java application or a Perl application or a C++ application or a BASIC application or a COBOL application ...lots of choices

Aside, you wouldn't read XML files and then create XSD. Creating the XSD comes first... you are thinking backwards!
Luke Murphy
Ranch Hand

Joined: May 12, 2010
Posts: 300
Jimmy Clark wrote:

Aside, you wouldn't read XML files and then create XSD. Creating the XSD comes first... you are thinking backwards!

Agree. I don't make some choices. The organisation I am involved with did a few years back and we are stuck with them.
Jimmy Clark
Ranch Hand

Joined: Apr 16, 2008
Posts: 2187
Sounds good. Check out the Eclipse Modeling Framework (EMF). It represents a clean strategy for building applications based upon a data model.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Generating XSD
 
Similar Threads
Internationalization using XSL.. Help Plz
xml databinding
many questions about ws
Quick Question - can we change business domain model ?
generating xml from xsd (urgent)