ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/main/java/util/Vector.java
(Generate patch)

Comparing jsr166/src/main/java/util/Vector.java (file contents):
Revision 1.15 by jsr166, Sun Jun 25 19:58:14 2006 UTC vs.
Revision 1.16 by jsr166, Sun Jun 25 20:05:33 2006 UTC

# Line 233 | Line 233 | public class Vector<E>
233       * the vector. If the new size is less than the current size, all
234       * components at index {@code newSize} and greater are discarded.
235       *
236 <     * @param   newSize   the new size of this vector
237 <     * @throws  ArrayIndexOutOfBoundsException if new size is negative
236 >     * @param  newSize   the new size of this vector
237 >     * @throws ArrayIndexOutOfBoundsException if the new size is negative
238       */
239      public synchronized void setSize(int newSize) {
240          modCount++;
# Line 461 | Line 461 | public class Vector<E>
461      /**
462       * Sets the component at the specified {@code index} of this
463       * vector to be the specified object. The previous component at that
464 <     * position is discarded.<p>
464 >     * position is discarded.
465       *
466 <     * The index must be a value greater than or equal to {@code 0}
467 <     * and less than the current size of the vector. <p>
466 >     * <p>The index must be a value greater than or equal to {@code 0}
467 >     * and less than the current size of the vector.
468       *
469 <     * This method is identical in functionality to the set method
469 >     * <p>This method is identical in functionality to the set method
470       * (which is part of the List interface). Note that the set method reverses
471       * the order of the parameters, to more closely match array usage.  Note
472       * also that the set method returns the old value that was stored at the
# Line 562 | Line 562 | public class Vector<E>
562      /**
563       * Adds the specified component to the end of this vector,
564       * increasing its size by one. The capacity of this vector is
565 <     * increased if its size becomes greater than its capacity. <p>
565 >     * increased if its size becomes greater than its capacity.
566       *
567 <     * This method is identical in functionality to the add(Object) method
567 >     * <p>This method is identical in functionality to the add(Object) method
568       * (which is part of the List interface).
569       *
570       * @param   obj   the component to be added
# Line 582 | Line 582 | public class Vector<E>
582       * from this vector. If the object is found in this vector, each
583       * component in the vector with an index greater or equal to the
584       * object's index is shifted downward to have an index one smaller
585 <     * than the value it had previously.<p>
585 >     * than the value it had previously.
586       *
587 <     * This method is identical in functionality to the remove(Object)
587 >     * <p>This method is identical in functionality to the remove(Object)
588       * method (which is part of the List interface).
589       *
590       * @param   obj   the component to be removed
# Line 655 | Line 655 | public class Vector<E>
655       * correct order; the runtime type of the returned array is that of the
656       * specified array.  If the Vector fits in the specified array, it is
657       * returned therein.  Otherwise, a new array is allocated with the runtime
658 <     * type of the specified array and the size of this Vector.<p>
658 >     * type of the specified array and the size of this Vector.
659       *
660 <     * If the Vector fits in the specified array with room to spare
660 >     * <p>If the Vector fits in the specified array with room to spare
661       * (i.e., the array has more elements than the Vector),
662       * the element in the array immediately following the end of the
663       * Vector is set to null.  (This is useful in determining the length
# Line 668 | Line 668 | public class Vector<E>
668       *          be stored, if it is big enough; otherwise, a new array of the
669       *          same runtime type is allocated for this purpose.
670       * @return an array containing the elements of the Vector
671 <     * @exception ArrayStoreException the runtime type of a is not a supertype
671 >     * @throws ArrayStoreException the runtime type of a is not a supertype
672       * of the runtime type of every element in this Vector
673       * @throws NullPointerException if the given array is null
674       * @since 1.2
# Line 1145 | Line 1145 | public class Vector<E>
1145       * equal, the returned List is empty.)  The returned List is backed by this
1146       * List, so changes in the returned List are reflected in this List, and
1147       * vice-versa.  The returned List supports all of the optional List
1148 <     * operations supported by this List.<p>
1148 >     * operations supported by this List.
1149       *
1150 <     * This method eliminates the need for explicit range operations (of
1150 >     * <p>This method eliminates the need for explicit range operations (of
1151       * the sort that commonly exist for arrays).   Any operation that expects
1152       * a List can be used as a range operation by operating on a subList view
1153       * instead of a whole List.  For example, the following idiom
# Line 1157 | Line 1157 | public class Vector<E>
1157       * </pre>
1158       * Similar idioms may be constructed for indexOf and lastIndexOf,
1159       * and all of the algorithms in the Collections class can be applied to
1160 <     * a subList.<p>
1160 >     * a subList.
1161       *
1162 <     * The semantics of the List returned by this method become undefined if
1162 >     * <p>The semantics of the List returned by this method become undefined if
1163       * the backing list (i.e., this List) is <i>structurally modified</i> in
1164       * any way other than via the returned List.  (Structural modifications are
1165       * those that change the size of the List, or otherwise perturb it in such

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines