You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by "Henning P. Schmiedehausen" <hp...@intermeta.de> on 2004/05/10 01:43:00 UTC

Re: cvs commit:

Peter Courcoux <pe...@courcoux.biz> writes:

Folks,

what's so special with ArrayList that it deserves an

>>   +                if (value instanceof ArrayList) {
>>   +                    for (Iterator itr = ((ArrayList)value).iterator(); itr.hasNext();)
>>   +                    {
>>   +                        veloConfig.addProperty(key, itr.next());
>>   +                    }

IMNSVHO

import java.util.List;

if (value instanceof List)
{
    for(Iterator it = ((List) value).iterator(); it.hasNext(); )
    {
        veloConfig.addProperty(key, it.next());
    }
}

would not only work as good, but would allow users, that prefer other
types of List implementations to use this as well.

Also: space style, bracket style. :-/

Or am I missing something here�

	Regards
		Henning

-- 
Dipl.-Inf. (Univ.) Henning P. Schmiedehausen          INTERMETA GmbH
hps@intermeta.de        +49 9131 50 654 0   http://www.intermeta.de/

RedHat Certified Engineer -- Jakarta Turbine Development  -- hero for hire
   Linux, Java, perl, Solaris -- Consulting, Training, Development

"Au�erdem k�nnen in Deutschland alle Englisch. [...] so entf�llt die
Notwendigkeit [...] Deutsch zu lernen." 
            -- Johan Micoud auf die Frage warum er kein Deutsch spricht.
                   (http://www.spiegel.de/spiegel/0,1518,273205,00.html)

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