You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xmlbeans-user@xml.apache.org by "Dunlop, Aaron" <aa...@transcore.com> on 2004/01/13 18:54:55 UTC

RE: How to find Java Types generated from User-Derived Schema Typ es

One possibility is to use the '-src' flag on scomp (specifying a source
directory). This will generate java source files as well as the classfile
jar.
 
For whatever it's worth, we generate a source jar as well as the classfile
jar with debug information enabled, and link them in our IDE for
development. This allows us to examine the source code and debug through it
during development, while deploying only the classfile jar.
 
Hope that helps,
Aaron Dunlop

-----Original Message-----
From: Lateef, Irfan, ALABS [mailto:lateef@att.com]
Sent: Tuesday, January 13, 2004 6:42 AM
To: xmlbeans-user@xml.apache.org
Subject: How to find Java Types generated from User-Derived Schema Types


Hi,
 
In the documnetation section "Java Types Generated from User-Derived Schema
Types"
 
The example of price-quote schema has the following sample code.

public static float getStockPrice(java.io.File orderXML) throws Exception 

{

    PriceQuoteDocument docXML = PriceQuoteDocument.Factory.parse(orderXML);

    PriceQuote quoteXML = docXML.getPriceQuote();

    float stockPrice = quoteXML.getStockPrice();

    return stockPrice;

}


And the documentation explains that the way name translations are done as
follows,
"The way this name translation is done is described by section C of the Java
API for XML 
Binding (JAXB) specification at  http://java.sun.com/xml/jaxb.html.
<http://java.sun.com/xml/downloads/jaxb.html>  "
Now my question, I have a very complex XSD and it is extremely difficult to
read the rules and 
guess the java interfaces. Is there a way to access the generated code
directly and see the
signatures of the generated java code and use them.
I tried the following, 
(1) jar -xvf fdr.jar - This is the jar generated by the scomp
(2) cd noNameSpace and javap OrderListDocument.class in the hope to see the
public interfaces
But the reponse is Error: Binary file OrderListDocument contains
noNameSpace.OrderListDocument 
I am trying to find the getPriceQuote/setPriceQuote find of functions.
Earlier I was using a JAXB implementation and I could go into the
generatedtypes dir and directly see *.java code.
Appreciate your help and thanks in advance.
Irfan Lateef
AT&T Labs, Middletown, NJ
lateef@att.com <ma...@att.com>