Re: JSR311: _at_*Param and List<?>

From: Bill Burke <>
Date: Tue, 18 Mar 2008 08:53:33 -0400

Stephan Koops wrote:
> Hello Paul, hello Bill,
>>>> I think it is useful to allow also Set and SortedSet. Sometimes the
>>>> order is irrelevant and/or dublicates could or should be ignored for
>>>> the app. I propose also to allow Collection.
>> What would be the order and dups policy when Collection is specified?
>> I don't think Collection should be allowed and the developer should be
>> explicit about the ordering/dups through the Java type specified.
> Doesn't matter, that means runtime environment is free to choose. If a
> method requires a Collection, there is never a order defined.
> If a method (in general) want to be as flexible as possible, it should
> allows Collection. The idea was, to also allow this flexibility here.
>> If we are trying to keep things immutable then should arrays of stuff
>> should be allowed?
> We can avoid the modification on Collections, so we should do that. If
> we can't avoid this on arrays, doesn't matter ... (IMO)
> The argument for me for the arrays is, that they could be iterated and
> accessed very fast (compared to Lists). But if someone needs speed, he
> should not use a specification, which requires a lot of using of
> reflections ...
> Bill, what do you say? You proposed the array.

I don't care that much to support arrays. We already support it in our
implementation so it doesn't matter to me if its in or not.

Bill Burke
JBoss, a division of Red Hat