CompositeDisposable.CopyTo(IDisposable[], int) method¶
Defined in
Type: CompositeDisposable
Namespace: System.Reactive.Disposables
Assembly: System.Reactive.dll
Applies to
netstandard2.0, net472
public void CopyTo(IDisposable[] array, int arrayIndex)
Inherited documentation
These docs were inherited from ICollection<IDisposable>. The member doesn't override them on this type.
Summary: Copies the elements of the ICollection (opens in a new tab) to an Array (opens in a new tab), starting at a particular Array (opens in a new tab) index.
Parameters
| Name | Type | Description |
|---|---|---|
array | IDisposable[] | The one-dimensional Array (opens in a new tab) that is the destination of the elements copied from ICollection (opens in a new tab). The Array (opens in a new tab) must have zero-based indexing. |
arrayIndex | int (opens in a new tab) | The zero-based index in array at which copying begins. |
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentNullException (opens in a new tab) | array is null. |
| System.ArgumentOutOfRangeException (opens in a new tab) | arrayIndex is less than 0. |
| System.ArgumentException (opens in a new tab) | The number of elements in the source ICollection (opens in a new tab) is greater than the available space from arrayIndex to the end of the destination array. |