You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Thomas Neidhart (JIRA)" <ji...@apache.org> on 2013/02/28 20:39:17 UTC
[jira] [Reopened] (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 ]
Thomas Neidhart reopened COLLECTIONS-288:
-----------------------------------------
> 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: 4.0
>
>
> 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.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira