< prev index next >
src/java.base/share/classes/java/util/Collections.java
Print this page
rev 12854 : [mq]: 8138938-Clarify-javadoc-for-java-util-Collections-copy
*** 535,546 ****
/**
* Copies all of the elements from one list into another. After the
* operation, the index of each copied element in the destination list
* will be identical to its index in the source list. The destination
! * list must be at least as long as the source list. If it is longer, the
! * remaining elements in the destination list are unaffected. <p>
*
* This method runs in linear time.
*
* @param <T> the class of the objects in the lists
* @param dest The destination list.
--- 535,547 ----
/**
* Copies all of the elements from one list into another. After the
* operation, the index of each copied element in the destination list
* will be identical to its index in the source list. The destination
! * list's size must be greater than or equal to the source list's size.
! * If it is greater, the remaining elements in the destination list are
! * unaffected. <p>
*
* This method runs in linear time.
*
* @param <T> the class of the objects in the lists
* @param dest The destination list.
< prev index next >