com.sodius.mdw.core.model
Class DefaultMDWList<E>

java.lang.Object
  extended by 
      extended by com.sodius.mdw.core.model.DefaultMDWList<E>
All Implemented Interfaces:
MDWEList<E>, MDWCollection<E>, MDWList<E>, Iterable<E>, Collection<E>

public class DefaultMDWList<E>
extends
implements MDWEList<E>

Default MDWList implementation based on an ArrayList.

See Also:
ArrayList

Constructor Summary
DefaultMDWList()
          Constructs an empty list with an initial capacity of ten.
DefaultMDWList(Collection<E> c)
          Constructs a list containing the elements of the specified collection, in the order they are returned by the collection's iterator.
DefaultMDWList(int initialCapacity)
          Constructs an empty list with the specified initial capacity.
 
Method Summary
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.sodius.mdw.core.model.MDWList
collect, collect, collect, concat, concat, concat, concat, concat, concat, copy, detect, detect, detect, first, getInstances, getInstances, getInstances, getInstances, getProfiledInstances, getProfiledInstances, getProfiledInstances, getProfiledInstances, last, reject, reject, reject, reverse, select, select, select, sort, sort, sort, toSet
 
Methods inherited from interface java.util.Collection
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
 

Constructor Detail

DefaultMDWList

public DefaultMDWList()
Constructs an empty list with an initial capacity of ten.


DefaultMDWList

public DefaultMDWList(int initialCapacity)
Constructs an empty list with the specified initial capacity.

Parameters:
initialCapacity - the initial capacity of the list.
Throws:
IllegalArgumentException - if the specified initial capacity is negative

DefaultMDWList

public DefaultMDWList(Collection<E> c)
Constructs a list containing the elements of the specified collection, in the order they are returned by the collection's iterator. The DefaultMDWList instance has an initial capacity of 110% the size of the specified collection.

Parameters:
c - the collection whose elements are to be placed into this list.
Throws:
NullPointerException - if the specified collection is null.