Done. http://jira.codehaus.org/browse/CASTOR-2422
Werner Guttmann wrote:
Sure. Can you please add a new Jira issue (e.g. a task) asking us to
update the relevant documentation. If you had some time to identify the
relevant areas where that 'feature' should be documented, that would be
great. If you provided us with a patch, this would be really appreciated.
Regards
Werner
Elvedin Trnjanin wrote:
A coworker figured out the this issue. The project had its own
implementation of equals and hashCode which lead to Castor assuming
subsequent objects were the same as the one already added, so they were
skipped. This would be a good note to add in the documentation (or
perhaps I've missed it somewhere).
Regards,
Elvedin
Werner Guttmann wrote:
Hi Elvedin,
Elvedin Trnjanin wrote:
I used MappingTool to map the classes and then edited the result to fit
the provided XML file.
That should not make a difference at all.
The MappingTool didn't have any issues with
Hibernate, nor did I find anything on the Castor web site to indicate
any special handling of this situation. Hibernate probably isn't an
issue because always at least one item (when available in XML) is added
to the Set, but never more than one. Why would unmarshalling skip an
item for a collection?
Not sure. I'd like to have a look at this somehow, but without you being
able to strip this down to the bare essentials ... this will be hard to
do (read a bit too time consuming for myself).
Werner Guttmann wrote:
Hi,
extension hierarchies should not really make a difference, as far as I
can tell (as Castor can cope with pretty much any typical OO
construct).
The use of Hibernate (for persistence, I assume) could make a bit of a
difference, though.
Werner
Elvedin Trnjanin wrote:
I have tested with another project and it works correctly. There are
some differences, such as the project that isn't working is using
Hibernate and extends "reverse engineering" classes, while the ones
that
do work are simple objects. I'll keep debugging and make a new Jira
issue if I do find a bug in Castor.
Werner Guttmann wrote:
Not sure. Afair, we've got a test case that covers collections in
general and sets in particular.
Can you please open a new Jira issue and attach all relevant files so
that we could replay this problem.
Regards
Werner
Elvedin Trnjanin wrote:
Hello all,
I'm trying to unmarshal an XML file with the structure of
<something> <!-- not a class, just something -->
<aclass>
<member> <!-- member is a class too -->
</member>
<member>
</member>...
</aclass>
</something>
Mapping file:
<class name"a.package.aclass">
...
<field name="member" type="a.package.Member" collection="set">
<bind-xml name="member" location ="aclass" />
</field>
...
</class>
Everything else maps properly, however only the first members is
put in
the Set, all of the other ones are ignored. Is this a mapping
issue or
something with the constructor(s)/set method(s)?
Regards,
Elvedin
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email