60 |
|
private E[] array() { return array_; } |
61 |
|
|
62 |
|
/** |
63 |
< |
* Constructs an empty list |
64 |
< |
* |
63 |
> |
* Constructs an empty list. |
64 |
|
*/ |
65 |
|
public CopyOnWriteArrayList() { |
66 |
|
array_ = (E[]) new Object[0]; |
81 |
|
} |
82 |
|
|
83 |
|
/** |
84 |
< |
* Create a new CopyOnWriteArrayList holding a copy of given array |
85 |
< |
* @param toCopyIn the array. A copy of this array is used as the |
86 |
< |
* internal array. |
84 |
> |
* Create a new CopyOnWriteArrayList holding a copy of given array. |
85 |
> |
* |
86 |
> |
* @param toCopyIn the array (a copy of this array is used as the |
87 |
> |
* internal array) |
88 |
|
**/ |
89 |
|
public CopyOnWriteArrayList(E[] toCopyIn) { |
90 |
|
copyIn(toCopyIn, 0, toCopyIn.length); |
968 |
|
* List, so changes in the returned List are reflected in this List, and |
969 |
|
* vice-versa. While mutative operations are supported, they are |
970 |
|
* probably not very useful for CopyOnWriteArrays. |
971 |
< |
* </p> |
971 |
> |
* <p> |
972 |
|
* The semantics of the List returned by this method become undefined if |
973 |
|
* the backing list (i.e., this List) is <i>structurally modified</i> in |
974 |
|
* any way other than via the returned List. (Structural modifications are |