The maven 1 (hosted at xmlbeans) and maven 2 (I think hosted with maven 2) xmlbeans plugins may not put the original schemas in this location. I'd like to investigate and fix that. Is there a specification for what GeneratedXMLBean.type.getSourceName() returns? Is it the file name with no path of the original schema? If so, what happens when you compile 2 schemas with the same file name but different namespaces into the same jar (e.g. they were located in different directories).

Thanks
david jencks


On Oct 4, 2005, at 10:36 AM, Cezar Andrei wrote:

Scomp saves the original schema files inside the generated jar, and you
can get to it in the following way:

InputStream is =
XMLParsers.class.getClassLoader().getResourceAsStream("schemaorg_apache _
xmlbeans/src/" + GeneratedXMLBean.type.getSourceName());

Cezar

-----Original Message-----
From: Eran Chinthaka [mailto:[EMAIL PROTECTED]
Sent: Tuesday, October 04, 2005 11:33 AM
To: user@xmlbeans.apache.org
Subject: Re-Generating schema from the generated code

Hi,

I'm from Apache Axis2 team. I need a help in generating schema using
XMLBeans.
My scenario is like this. I have bunch of classes created using a
given
xml schema, by XMLBeans. But at some time, I do not have the schema
file
which was used to generate the code, but I have all the classes
generated using that schema by xml beans. Now I want to
generate/derive
the schema from the classes I have.
I load the generated classes using a proper class loader and I could
find all the generated codes which are global elements. How can I
recreate the schema which was used to generate this code. I don't have
the initial schema file by now. I want to derive it using the classes
I
have.
Any help in this is very much appreciated.

(Sorry If I'm repeating this question on this list. I searched in the
archives, but didn't find something similar to this.)

Thanks,
Chinthaka


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to