< prev index next >

src/java.base/share/classes/java/util/Vector.java

Print this page




  85  *
  86  * @author  Lee Boynton
  87  * @author  Jonathan Payne
  88  * @see Collection
  89  * @see LinkedList
  90  * @since   1.0
  91  */
  92 public class Vector<E>
  93     extends AbstractList<E>
  94     implements List<E>, RandomAccess, Cloneable, java.io.Serializable
  95 {
  96     /**
  97      * The array buffer into which the components of the vector are
  98      * stored. The capacity of the vector is the length of this array buffer,
  99      * and is at least large enough to contain all the vector's elements.
 100      *
 101      * <p>Any array elements following the last element in the Vector are null.
 102      *
 103      * @serial
 104      */

 105     protected Object[] elementData;
 106 
 107     /**
 108      * The number of valid components in this {@code Vector} object.
 109      * Components {@code elementData[0]} through
 110      * {@code elementData[elementCount-1]} are the actual items.
 111      *
 112      * @serial
 113      */
 114     protected int elementCount;
 115 
 116     /**
 117      * The amount by which the capacity of the vector is automatically
 118      * incremented when its size becomes greater than its capacity.  If
 119      * the capacity increment is less than or equal to zero, the capacity
 120      * of the vector is doubled each time it needs to grow.
 121      *
 122      * @serial
 123      */
 124     protected int capacityIncrement;




  85  *
  86  * @author  Lee Boynton
  87  * @author  Jonathan Payne
  88  * @see Collection
  89  * @see LinkedList
  90  * @since   1.0
  91  */
  92 public class Vector<E>
  93     extends AbstractList<E>
  94     implements List<E>, RandomAccess, Cloneable, java.io.Serializable
  95 {
  96     /**
  97      * The array buffer into which the components of the vector are
  98      * stored. The capacity of the vector is the length of this array buffer,
  99      * and is at least large enough to contain all the vector's elements.
 100      *
 101      * <p>Any array elements following the last element in the Vector are null.
 102      *
 103      * @serial
 104      */
 105     @SuppressWarnings("serial") // Not statically typed as Serializable
 106     protected Object[] elementData;
 107 
 108     /**
 109      * The number of valid components in this {@code Vector} object.
 110      * Components {@code elementData[0]} through
 111      * {@code elementData[elementCount-1]} are the actual items.
 112      *
 113      * @serial
 114      */
 115     protected int elementCount;
 116 
 117     /**
 118      * The amount by which the capacity of the vector is automatically
 119      * incremented when its size becomes greater than its capacity.  If
 120      * the capacity increment is less than or equal to zero, the capacity
 121      * of the vector is doubled each time it needs to grow.
 122      *
 123      * @serial
 124      */
 125     protected int capacityIncrement;


< prev index next >