• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

can't create java objects from schemas using xjc

 
sanat
Ranch Hand
Posts: 111
Eclipse IDE Java Mac
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,

i'm new to web services, i was just trying to generate java classes from my schemas, using xjc ant task. but it always complains.

schema
------


ant task
--------


error
-----


i have really no idea what's wrong here. any help would be appreciated. thanks in advance.

-sanat
 
Paulo Salgado
Ranch Hand
Posts: 98
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Sanat.

It looks like you have a conflict between the element name and the type name. JAXB will generate interfaces and classes for both, so they can't have the same name. Try renaming either one of them. For instance, rename the element on your XML Schema like this:



Regards.
 
Don't get me started about those stupid light bulbs.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic