C# Class PortableRx.Reactive.Disposables.AnonymousDisposable

Represents an Action-based disposable.
Inheritance: ICancelable
Mostrar archivo Open project: robfe/PortableRx

Public Methods

Method Description
AnonymousDisposable ( System.Action dispose ) : System

Constructs a new disposable with the given action used for disposal.

Dispose ( ) : void

Calls the disposal action if and only if the current instance hasn't been disposed yet.

Method Details

AnonymousDisposable() public method

Constructs a new disposable with the given action used for disposal.
public AnonymousDisposable ( System.Action dispose ) : System
dispose System.Action Disposal action which will be run upon calling Dispose.
return System

Dispose() public method

Calls the disposal action if and only if the current instance hasn't been disposed yet.
public Dispose ( ) : void
return void