Hi Alexander,

I don't understand why you'd get this particular problem, since the schema generator uses the same validation code as the binding compiler. But the schema generator tool is in need of an update in any case to bring it up to par with the changes to JiBX. I probably won't get to it until around the end of the year, though. In the meantime, I'd recommend you work around it by leaving off the attribute and hand-modifying the generated schema.

 - Dennis

Niemann Alexander wrote:

Hello everybody,

I am having a problem with the SchemaGenerator delivered in jibx-genschema.jar. The binding itself works so far and now I need the tool to create a schema description (XSD file) which has to be imported into another tool. Running the generator I get this error message:

generate-jibx-schema:
     [java] Running schema generator version 0.2
     [java] Problems found in binding null
[java] Only one child ID property allowed for an object - value element at (line 39, col 62, in config_mappings_jibx_binding_xml) and value element at (line 39, col 62, in config_mappings_jibx_binding_xml) refer to the same object for value element at (line 39, col 62, in config_mappings_jibx_binding_xml)

     [java] Binding validation errors prevent schema generation

My binding looks like this:

  <mapping class="de.ava.kas.model.DealHead" name="deal-head">
    <value name="deal-id-str" field="dealIdStr" ident="def"/>

    <collection field="dealDetails" name="deal-details" usage="optional"
                item-type="de.ava.kas.model.DealDetail"
                type="java.util.HashSet"
    />

    <!-- lots of other values, structures and collections follow here -->
  </mapping>
  <mapping name="deal-detail" class="de.ava.kas.model.DealDetail">
    <!-- lots of values and structures here -->
    <value name="dealHead" field="dealHead" ident="ref"/>
  </mapping>

As soon as I remove 'ident="ref"' from 'deal-id-str' the schema generation works but the binding itself fails. Does anyone has a clue what might be the problem here?

Thanks in advance
Alexander



-------------------------------------------------------
This SF.Net email is sponsored by the JBoss Inc.
Get Certified Today * Register for a JBoss Training Course
Free Certification Exam for All Training Attendees Through End of 2005
Visit http://www.jboss.com/services/certification for more information
_______________________________________________
jibx-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to