I just tried this with the latest code, and although the problem you're 
encountering with 1.2.1 has been fixed there's still another issue. I'll 
get that fixed today and have it in place for the 1.2.2 release next week.

That's my least-favorite schema style, by the way, with all the global 
element definitions. Makes a good test case, but you'll probably want to 
tell CodeGen to inline everything except the elements actually used as 
document roots so that you don't end up with dozens of classes 
consisting only of a single String (or BigInt, or Date) value.

  - Dennis

Dennis M. Sosnoski
XML and Web Services in Java
Training and Consulting
http://www.sosnoski.com - http://www.sosnoski.co.nz
Seattle, WA +1-425-939-0576 - Wellington, NZ +64-4-298-6117



Whiz wrote:
> Sorry folks.. Just noticed the extra space in the link for xsd. The 
> correct URL is: http://docs.google.com/View?id=d4dhmdm_17x7wrdf9
> Could someone please suggest why JiBX cannot gen code for this xsd?
>  
> Thanks!
> --- On *Fri, 11/13/09, Whiz /<vyakaranam_2...@yahoo.com>/* wrote:
>
>
>     From: Whiz <vyakaranam_2...@yahoo.com>
>     Subject: Re: [jibx-users] Codegen fails with NullPointerException
>     To: jibx-users@lists.sourceforge.net
>     Date: Friday, November 13, 2009, 10:06 AM
>
>     I had posted that xsd resulting in a NullPointerException to
>     internet at http://docs.google.com/View?id=d4dhmdm_17x7wrdf9 
>     Thanks
>
>
>         From: Whiz <vyakaranam_2...@yahoo.com>
>         Subject: Codegen fails with NullPointerException
>         To: jibx-users@lists.sourceforge.net
>         Date: Friday, November 13, 2009, 9:17 AM
>
>         Hi All,
>          
>         When attempting to generate code from a xsd, I am  getting a
>         NullPointerException as pasted in the end below. Generated a
>         debug jibx log, and it appears like it logs almost til the end
>         of the xsd with just 2 more simpleType's left to go. Zero
>         source code files are generated.
>          
>         INFO codegen.CodeGen - After inlining and classification for
>         complexType TRANS_SUBTYPE_CODES (XTbML2.21.00:674):
>         definition with 1 references (inlining blocked), and class
>         name TRANSSUBTYPECODES (not all items optional): complexType
>         TRANS_SUBTYPE_CODES (XTbML2.21.00:674)
>         inlined group with class name String and value name string
>         (all items optional): extension (XTbML2.21.00:676)
>         .value of type java.lang.String with value name string:
>         extension (XTbML2.21.00:676)
>         inlined group with class name Tc and value name tc (not all
>         items optional): attribute tc (XTbML2.21.00:676)
>         .value of type java.math.BigInteger with value name null:
>         attribute tc (XTbML2.21.00:676)
>          
>          
>         No source files are eventually generated.
>          
>          
>         Based on limitations of codegen found on website, made sure
>         <xs:any> is last in sequece and <xs:anyAttribute> does not exist
>          
>         Know that this is the first time we are using jibx to gen real
>         code after going thro' docs and running some samples.
>          
>         What are we missing? Help!
>          
>         C:\workspaces\CheckItOut\codegenjibx\jibx\dwcode2>java -cp
>         .;..\lib\jibx-tools.j
>         ar org.jibx.schema.codegen.CodeGen -t gen\src -w -v
>         *XTbML2.21.00.xsd*
>         Output to directory gen\src
>         Loaded and validated 1 specified schema(s):
>          top-level schema XTbML2.21.00.xsd
>         Exception in thread "main" *java.lang.NullPointerException*
>                 at
>         org.jibx.schema.codegen.ClassHolder$DataNode.<init>(ClassHolder.java:
>         815)
>                 at
>         org.jibx.schema.codegen.StructureClassHolder.addToTree(StructureClass
>         Holder.java:281)
>                 at
>         org.jibx.schema.codegen.StructureClassHolder.addToTree(StructureClass
>         Holder.java:214)
>                 at
>         org.jibx.schema.codegen.StructureClassHolder.buildDataStructure(Struc
>         tureClassHolder.java:309)
>                 at
>         org.jibx.schema.codegen.CodeGen.generate(CodeGen.java:1383)
>                 at org.jibx.schema.codegen.CodeGen.main(CodeGen.java:1652)
>
>
>
>
>     -----Inline Attachment Follows-----
>
>     
> ------------------------------------------------------------------------------
>     Let Crystal Reports handle the reporting - Free Crystal Reports
>     2008 30-Day
>     trial. Simplify your report design, integration and deployment -
>     and focus on
>     what you do best, core application coding. Discover what's new with
>     Crystal Reports now.  http://p.sf.net/sfu/bobj-july
>
>     -----Inline Attachment Follows-----
>
>     _______________________________________________
>     jibx-users mailing list
>     jibx-users@lists.sourceforge.net
>     
> <http://us.mc382.mail.yahoo.com/mc/compose?to=jibx-us...@lists.sourceforge.net>
>     https://lists.sourceforge.net/lists/listinfo/jibx-users
>
>
> ------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
> trial. Simplify your report design, integration and deployment - and focus on 
> what you do best, core application coding. Discover what's new with
> Crystal Reports now.  http://p.sf.net/sfu/bobj-july
> ------------------------------------------------------------------------
>
> _______________________________________________
> jibx-users mailing list
> jibx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jibx-users
>   

------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to