[ 
https://issues.apache.org/jira/browse/MAHOUT-889?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13152150#comment-13152150
 ] 

Claudio Martella commented on MAHOUT-889:
-----------------------------------------

I don't get it. What do you need exactly that the sample doesn't say already?
For what it's worth:

{code}
import static org.junit.Assert.*;

import org.apache.mahout.math.list.ObjectArrayList;
import org.junit.Test;

public class MAHOUT889 {
    
        private ObjectArrayList<String> list = new ObjectArrayList<String>();
        
    @Test
    public void testSizeReturns0onFreshObject() {
        assertTrue(list.size() == 0);
    }
}
{code}



                
> size() returns wrong value (10) on freshly instantiated ObjectArrayList.
> ------------------------------------------------------------------------
>
>                 Key: MAHOUT-889
>                 URL: https://issues.apache.org/jira/browse/MAHOUT-889
>             Project: Mahout
>          Issue Type: Bug
>          Components: collections
>    Affects Versions: collections-1.0
>            Reporter: Claudio Martella
>            Assignee: Benson Margulies
>
> ObjectArrayList returns 10 for a freshly instantiated object:
> {code}
> ObjectArrayList<String> list = new ObjectArrayList<String>();
> System.out.println(list.size());
> {code}
> prints 10.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to