commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Thomas Neidhart (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (COLLECTIONS-459) ArrayIterator & ObjectArrayIterator - do they need setters?`
Date Mon, 17 Jun 2013 20:28:20 GMT

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

Thomas Neidhart resolved COLLECTIONS-459.
-----------------------------------------

    Resolution: Fixed

In r1493922, I have removed the setArray methods and the default constructors.
The fields have been made final if possible (apart from the actual index used for the iteration).
I have kept them protected to make the access in the derived classes (ArrayListIterator, ObjectArrayListIterator)
easier.
                
> ArrayIterator & ObjectArrayIterator - do they need setters?`
> ------------------------------------------------------------
>
>                 Key: COLLECTIONS-459
>                 URL: https://issues.apache.org/jira/browse/COLLECTIONS-459
>             Project: Commons Collections
>          Issue Type: Bug
>            Reporter: Sebb
>             Fix For: 4.0
>
>
> ArrayIterator & ObjectArrayIterator both have methods to set the array separately
from the ctor.
> However the method does not allow the same flexibility as the ctor, as it does not allow
the start or end indexes to be set.
> Is there really a use-case for these setters? If not, all the fields apart from index
could be made final, which would make thread safety (and testing) easier.

--
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

Mime
View raw message