Hi,

Can a set accessor for a multi-valued relationship be called with an
arbitrary java.util.Set or java.util.Collection, as long as the contents
of that collection are of the correct type? Or is the set accessor for
multi-valued relationships strictly used for collections from the
same cmr field in different instances, the behavior of which is
described in 10.3.6.2 and 10.3.7? For instance, look at the
following passage:

"The Bean Provider can thus use the set method to move objects
between the collections referenced by cmr-fields of the same
relationship type in different instances. The set accessor method,
when applied to a cmr-field in a one-
to-many relationship thus has the semantics of the
java.util.Collection methods clear, followed by addAll, applied to the
target collection; and clear, applied to the source collection. It is the
responsibility of the container to transfer the contents of the
collection instances in the same transaction context."

It doesn't make sense that the container would call "clear" on the
source collection in the case that the source collection is a generic
collection class. But this passage could be read as describing the
special case that the bean provider is using the set cmr accessor
to move objects between different instances, without being
prescriptive.

Thanks,

Dan

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to