diff options
author | Tom Tromey <tromey@redhat.com> | 2006-09-18 21:31:46 +0000 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 2006-09-18 21:31:46 +0000 |
commit | b6591f48586e483e3818ec20c50d1025bf4065d8 (patch) | |
tree | 0f1cd0f193d9547d2ceda053f5558ce5781b41f4 /java | |
parent | 228fc33f661314b6723b691635085ee4ff6a69b2 (diff) | |
download | classpath-b6591f48586e483e3818ec20c50d1025bf4065d8.tar.gz |
* java/util/concurrent/CopyOnWriteArrayList.java
(CopyOnWriteArrayList): New constructor.
Diffstat (limited to 'java')
-rw-r--r-- | java/util/concurrent/CopyOnWriteArrayList.java | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/java/util/concurrent/CopyOnWriteArrayList.java b/java/util/concurrent/CopyOnWriteArrayList.java index d116a0edc..ec2c90cc1 100644 --- a/java/util/concurrent/CopyOnWriteArrayList.java +++ b/java/util/concurrent/CopyOnWriteArrayList.java @@ -84,6 +84,20 @@ public class CopyOnWriteArrayList<E> extends AbstractList<E> implements } /** + * Construct a new ArrayList, and initialize it with the elements in the + * supplied array. + * + * @param array + * the array used to initialize this list + * @throws NullPointerException + * if array is null + */ + public CopyOnWriteArrayList(E[] array) + { + data = array.clone(); + } + + /** * Returns the number of elements in this list. * * @return the list size |