You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-dev@db.apache.org by "Thomas Dudziak (JIRA)" <ji...@apache.org> on 2005/04/11 17:04:16 UTC

[jira] Created: (OJB-19) OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class

OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class
---------------------------------------------------------------------------------------------------------------

         Key: OJB-19
         URL: http://issues.apache.org/jira/browse/OJB-19
     Project: OJB
        Type: Bug
  Components: PB-API  
    Versions: 1.0.3    
    Reporter: Thomas Dudziak
 Assigned to: Thomas Dudziak 
     Fix For: 1.0.4


In cases where the collection-descriptor of a field of type List/Set does not specify collection-class, OJB currently uses RemovalAwareCollection which is a List but not a Set.
Instead, OJB should use the field type, and either throw a metadata exception if none of the default collection classes can be assigned to it, or use a fitting default collection.
This also means that a RemovalAwareSet is needed (based upon ManageableHashSet).


-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Re: [jira] Created: (OJB-19) OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class

Posted by Martin Kalén <mk...@apache.org>.
Thomas Dudziak wrote:
>>As a side note: Jakob has refactored the implementations in OJB 1.1 -- where this
>>area is much cleaner and easier to maintain.
> 
> Yep, but this special case is no different in 1.1, because the
> RemovalAwareCollection is still the default even when Set is used as
> the field type.

OK, I thought I remembered that the "skew" default of a List/Vector
had also been reworked but it was a while ago I looked at it.

> Btw, Martin Taal asked for the introductin of a CollectionFactory
> which would allow for a nice handling of this. I think I add one to
> 1.1 this week.

Sounds good!

Regards,
  Martin

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Re: [jira] Created: (OJB-19) OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class

Posted by Thomas Dudziak <to...@gmail.com>.
> As a side note: Jakob has refactored the implementations in OJB 1.1 -- where this
> area is much cleaner and easier to maintain.

Yep, but this special case is no different in 1.1, because the
RemovalAwareCollection is still the default even when Set is used as
the field type. I've changed the handling already, but need to add a
RemovalAwareSet which is slightly more work in 1.1 because of the
Manageable/Tracking differences.
Btw, Martin Taal asked for the introductin of a CollectionFactory
which would allow for a nice handling of this. I think I add one to
1.1 this week.

Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


Re: [jira] Created: (OJB-19) OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class

Posted by Martin Kalén <mk...@apache.org>.
Thomas Dudziak (JIRA) wrote:
> In cases where the collection-descriptor of a field of type List/Set does not specify collection-class, OJB currently uses RemovalAwareCollection which is a List but not a Set.
> Instead, OJB should use the field type, and either throw a metadata exception if none of the default collection classes can be assigned to it, or use a fitting default collection.
> This also means that a RemovalAwareSet is needed (based upon ManageableHashSet).

As a side note: Jakob has refactored the implementations in OJB 1.1 -- where this
area is much cleaner and easier to maintain.

Regards,
  Martin

---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org


[jira] Resolved: (OJB-19) OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class

Posted by "Thomas Dudziak (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/OJB-19?page=history ]
     
Thomas Dudziak resolved OJB-19:
-------------------------------

     Resolution: Fixed
    Fix Version: 1.0.x CVS
                     (was: 1.0.4)

> OJB should respect Set/List as the field type for collection descriptors that do not specify a collection class
> ---------------------------------------------------------------------------------------------------------------
>
>          Key: OJB-19
>          URL: http://issues.apache.org/jira/browse/OJB-19
>      Project: OJB
>         Type: Bug
>   Components: PB-API
>     Versions: 1.0.3
>     Reporter: Thomas Dudziak
>     Assignee: Thomas Dudziak
>      Fix For: 1.0.x CVS

>
> In cases where the collection-descriptor of a field of type List/Set does not specify collection-class, OJB currently uses RemovalAwareCollection which is a List but not a Set.
> Instead, OJB should use the field type, and either throw a metadata exception if none of the default collection classes can be assigned to it, or use a fitting default collection.
> This also means that a RemovalAwareSet is needed (based upon ManageableHashSet).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-dev-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-dev-help@db.apache.org