commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Julien Aymé (JIRA) <>
Subject [jira] Commented: (LANG-336) Finally start using generics.
Date Mon, 04 Jun 2007 08:36:35 GMT


Julien Aymé commented on LANG-336:

Just a few comments on Generics and varargs:

Henri Yandell [24/May/07 11:12 AM]:
"I wonder if this kind of method can be legal... 

If the type T is not known, the correct syntax to write generic methods is:

public <T> T[] foo (T ... t) {
    return t;

If a special class C is needed:
public <T extends C> T[] foo (T ... t) {
    return t;
(This is just examples of what can be done with generics)

Anyway, I'd be glad to help,

> Finally start using generics.
> -----------------------------
>                 Key: LANG-336
>                 URL:
>             Project: Commons Lang
>          Issue Type: Improvement
>    Affects Versions: 2.3
>            Reporter: Hendrik Maryns
>             Fix For: LangTwo 1.0
>         Attachments: commons-lang-2.3-sources-generic.tar.gz, lang.patch
> It is obvious that the Jakarta  project is reluctant in starting to use the 'new' (how
old is it by now?) generics feature of Java.  Nevertheless some other people would like to
see it incorporated in the commons projects.
> I adapted commons Lang to usee generics.  Took me about an afternoon.  Would be nice
if something is done with it, except for only me using it in my projects.
> Some stuff will have to be changed to conform to guidelines and stuff.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message