Skip to content

RefCountDisposable class

Defined in

Namespace: System.Reactive.Disposables Assembly: System.Reactive.dll Full name: System.Reactive.Disposables.RefCountDisposable Modifiers: public sealed

Summary

Represents a disposable resource that only disposes its underlying disposable resource when all GetDisposable have been disposed.

Applies to

netstandard2.0

Class hierarchy
classDiagram
class RefCountDisposable
class ICancelable {
    <>
}
ICancelable <|.. RefCountDisposable
class IDisposable {
    <>
}
IDisposable <|.. RefCountDisposable

Implements: ICancelable, IDisposable

Constructors

NameSummary
.ctorInitializes a new instance of the [RefCountDisposable](# class with the specified disposable.

Properties

NameSummary
IsDisposedGets a value that indicates whether the object is disposed.

Methods

NameSummary
GetDisposableReturns a dependent disposable that when disposed decreases the refcount on the underlying disposable.
DisposeDisposes the underlying disposable only when all dependent disposables have been disposed.
Inherited members