You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Henri Yandell (JIRA)" <ji...@apache.org> on 2008/03/18 07:11:27 UTC

[jira] Closed: (COLLECTIONS-288) Javadoc: incorrect behavior explained for ListUtils.transformedList

     [ https://issues.apache.org/jira/browse/COLLECTIONS-288?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Henri Yandell closed COLLECTIONS-288.
-------------------------------------

    Resolution: Fixed

svn ci -m "Stressing that existing objects are not transformed as per Paul's request in COLLECTIONS-288" src/java/org/apache/commons/collections/ListUtils.java 

Sending        src/java/org/apache/commons/collections/ListUtils.java
Transmitting file data .
Committed revision 638227.

> Javadoc: incorrect behavior explained for ListUtils.transformedList
> -------------------------------------------------------------------
>
>                 Key: COLLECTIONS-288
>                 URL: https://issues.apache.org/jira/browse/COLLECTIONS-288
>             Project: Commons Collections
>          Issue Type: Bug
>          Components: List
>            Reporter: Paul Benedict
>             Fix For: 3.3
>
>
> The contract stated for ListUtils.transformedList is wrong. The list is not transformed -- it decorates the existing list and transforms NEW objects -- EXISTING objects are not transformed. 
> Compare this to the javadoc found in MapUtils.transformedMap:
> "This method returns a new map (decorating the specified map) that will transform any new entries added to it. Existing entries in the specified map will not be transformed. "
> That little missing piece of information messed me up. Just replace "map" with "list" and append it to the existing LilstUtils javadoc.

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