C# Class WebApplications.Utilities.Threading.BufferedAction

Inheritance: IDisposable
ファイルを表示 Open project: webappsuk/CoreLibraries Class Usage Examples

Public Properties

Property Type Description
Duration long

Public Methods

Method Description
BufferedAction ( [ action, System.Duration duration ) : NodaTime

Initializes a new instance of the BufferedAction class.

BufferedAction ( [ action, System.TimeSpan duration ) : NodaTime

Initializes a new instance of the BufferedAction class.

BufferedAction ( [ action, long duration ) : NodaTime

Initializes a new instance of the BufferedAction class.

Dispose ( ) : void

Disposes this instance.

Run ( ) : void

Buffers a call to the underlying action.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Disposes the specified instance.

disposing indicates whether the method was invoked from the IDisposable.Dispose implementation or from the finalizer. The implementation should check the parameter before accessing other reference objects. Such objects should only be accessed when the method is called from the IDisposable.Dispose implementation (when the disposing parameter is equal to ). If the method is invoked from the finalizer (disposing is false), other objects should not be accessed. The reason is that objects are finalized in an unpredictable order and so they, or any of their dependencies, might already have been finalized.

Method Details

BufferedAction() public method

Initializes a new instance of the BufferedAction class.
is . is less than or equal to zero.
public BufferedAction ( [ action, System.Duration duration ) : NodaTime
action [ The action.
duration System.Duration The duration is the amount of time the result of a successful execution is held, after the point a successful request was made.
return NodaTime

BufferedAction() public method

Initializes a new instance of the BufferedAction class.
is . is less than or equal to zero.
public BufferedAction ( [ action, System.TimeSpan duration ) : NodaTime
action [ The action.
duration System.TimeSpan The duration is the amount of time the result of a successful execution is held, after the point a successful request was made.
return NodaTime

BufferedAction() public method

Initializes a new instance of the BufferedAction class.
is . is less than or equal to zero.
public BufferedAction ( [ action, long duration ) : NodaTime
action [ The action.
duration long The duration is the amount of time the result of a successful execution is held, after the point a successful request was made.
return NodaTime

Dispose() public method

Disposes this instance.
public Dispose ( ) : void
return void

Dispose() protected method

Disposes the specified instance.

disposing indicates whether the method was invoked from the IDisposable.Dispose implementation or from the finalizer. The implementation should check the parameter before accessing other reference objects. Such objects should only be accessed when the method is called from the IDisposable.Dispose implementation (when the disposing parameter is equal to ). If the method is invoked from the finalizer (disposing is false), other objects should not be accessed. The reason is that objects are finalized in an unpredictable order and so they, or any of their dependencies, might already have been finalized.

protected Dispose ( bool disposing ) : void
disposing bool Whether this is disposing or finalizing.
return void

Run() public method

Buffers a call to the underlying action.
public Run ( ) : void
return void

Property Details

Duration public_oe property

The duration (in milliseconds) to buffer the action for.
public long Duration
return long