aspose file tools
The moose likes XML and Related Technologies and the fly likes Overloading a XSD section Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Barcodes with iOS this week in the iOS forum
or Core Java for the Impatient in the Java 8 forum!

JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "Overloading a XSD section" Watch "Overloading a XSD section" New topic

Overloading a XSD section

Randy Miller
Ranch Hand

Joined: Feb 13, 2012
Posts: 44
Hi ranchers!

I am currently working on some new features of my XML processing tool and occured a problem working with the XML scheme. Basically, my tool generates a user GUI based on a XML scheme(=XSD) and a corresponding XML. I use a GUI Engine to dynamically generate the GUI based on the XSD and fill the generated blank formular with the information provided by the XML. But there´s a problem in displaying the "<any...>" elements. The problem is simply caused by the underlying XSD declarations, but I am not allowed to change the XSD period. So, I got the idea to just temporarly alter the XSD to successfully process the now correctly displayed data. My basic idea goes something like this:

I wanna provide a mechanism to overload the problematic XSD section with a correct one. Just like this:

Basic XSD section:

Wanted XSD section:

So,I basically wanna exchange the basic XSD section in XSD file 1 with the wanted XSD section in XSD file 2. Again, I cannot change the basic XSD for good, just temporarely.
I just want to allow the user to easily overload a section by for example click a button.
The problem with the "any"-section just is, that ANYTHING can be written in there, so the GUI engine I am currently using, just has no clue what elements are inside the section <variableParameters> because the elements are not mentioned inside the XSD.

Long story, short question: Is there any way to realize the overloading process of a XSD?I searched for days now but haven´t found anything yet...
I agree. Here's the link:
subject: Overloading a XSD section