Dennis Sosnoski <[EMAIL PROTECTED]> writes:

> It's true that the JiBX handling using choice="true" is not
> completely equivalent to the schema <choice> particle, for either
> marshalling or unmarshalling.

As there's not much written about the xsd:choice support, could you
add some detail -- either here or to the JiBX documentation on the Web
-- as to the variations? The current documentation¹ has the following:

,----
| This properly accepts only one of the alternative elements in the
| group when unmarshalling, but will generate output with more than one
| of the alternatives when marshalling if the values are present (but
| see Verification hooks if you need to enforce the schema limits).
`----

The first clause is the subject of this thread: JiBX will accept no
more than one of the alternatives /if they're all qualified as
optional/, but it fails in that it will also accept zero of the
alternatives.

Are there any more equivalence differences to discuss not covered
above?

> It looks like I could probably handle the no matching value present
> case in the code generation without too much trouble

> if you want to enter an enhancement request Jira for this purpose
> I'll see about adding it in for an upcoming release.

That became JIRA issue JIBX-164:

  http://jira.codehaus.org/browse/JIBX-164

> But 100% schema compatibility is definitely not a goal for JiBX 1.X,
> and even for JiBX 2.0 I'm planning for better schema compatibility
> rather than 100%.

That's fair and is certainly your prerogative to set your own
goals. This xsd:choice issue just looks like a case of intending to
solve a particular problem and not noticing the small omission.


Footnotes: 
¹ http://jibx.sourceforge.net/schema.html

-- 
Steven E. Harris


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to