I've the following question:
Why is it not necessary to use a name of the list before the add-statement (add (pipedInstanceIterator.next())) ?
Thanks.
public class InstanceList extends ArrayList<Instance> implements Serializable, Iterable<Instance>, AlphabetCarrying
...
public void addThruPipe (Iterator<Instance> ii)
{
//for debug
Iterator<Instance> pipedInstanceIterator = pipe.newIteratorFrom(ii);
while (pipedInstanceIterator.hasNext())
{
add (pipedInstanceIterator.next());
//System.out.println("Add instance " + pipedInstanceIterator.next().getName());
}
}
this.