users@jaxb.java.net

Re: xjc binding compiler not generating impl/*.java files

From: Malachi de Ælfweald <malachid_at_gmail.com>
Date: Thu, 28 Jun 2007 14:14:47 -0700

Hi Geoff,

JAXB used to always generate the impl classes. Then we got a much cleaner
interface :)

You can still generate them if you really need them, but if you are just
looking for them because you thought they should be there, I would say
don't. The newer approach is much cleaner.

As a side note, you probably should take the jaxb1-impl.jar out of your
classpath; it can confuse the classpath.

Malachi

On 6/28/07, Geoff Winsor <gwinsor_at_sfu.ca> wrote:
>
> Hi,
> I am trying to use JAXB to marshal XML documents for a website I am
> working on. The process of first generating the JAXB classes from the
> XML schema using the xjc binding compiler seems easy but I am not able
> to generate the impl/ subdirectory and the implementations. I decided to
> take a step back and use the po.xsd schema which is used in a lot of
> JAXB tutorials, however the problem remains.
>
> Here is what I have entered at the command line:
> /usr/java/jaxb-ri-20070122/bin/xjc.sh -p primer.po -d
> /home//InnateDB/src/com/innatedb/ po.xsd
>
> The output I get:
> parsing a schema...
> compiling a schema...
> primer/po/Items.java
> primer/po/ObjectFactory.java
> primer/po/PurchaseOrderType.java
> primer/po/USAddress.java
>
> When I re-enter the command with the -debug option, I get:
>
> parsing a schema...
> compiling a schema...
> [INFO] generating code
> unknown location
>
> primer/po/Items.java
> primer/po/ObjectFactory.java
> primer/po/PurchaseOrderType.java
> primer/po/USAddress.java
> JAXBDebug.java
>
> The following JAXB-related jar files are in my classpath:
> activation.jar
> jaxb1-impl.jar
> jaxb-api-doc.zip
> jaxb-api.jar
> jaxb-api-src.zip
> jaxb-impl.jar
> jaxb-impl.src.zip
> jaxbw.jar
> jaxb-xjc.jar
> jaxb-xjc.src.zip
> jsr173_1.0_api.jar
> substance.jar
>
> I tried another binding compiler from my JDK1.6 distribution but still
> fail to generate the impl/*.java files.
> Any suggestions as to how I can fix this would be greatly appreciated.
> Thanks,
> Geoff
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
> For additional commands, e-mail: users-help_at_jaxb.dev.java.net
>
>