Skip to content

CompositeDisposable.Remove(IDisposable) method

Defined in

Type: CompositeDisposable Namespace: System.Reactive.Disposables Assembly: System.Reactive.dll

Applies to

netstandard2.0, net472

public bool Remove(IDisposable item)

Inherited documentation

These docs were inherited from ICollection<IDisposable>. The member doesn't override them on this type.

Summary: Removes the first occurrence of a specific object from the ICollection (opens in a new tab).

Parameters

NameTypeDescription
itemIDisposable (opens in a new tab)The object to remove from the ICollection (opens in a new tab).

Returns: bool (opens in a new tab) -- true if item was successfully removed from the ICollection (opens in a new tab); otherwise, false. This method also returns false if item is not found in the original ICollection (opens in a new tab).

Exceptions

TypeCondition
System.NotSupportedException (opens in a new tab)The ICollection (opens in a new tab) is read-only.