Click or drag to resize

DispatcherThrottle Class

Implements a simple throttle that uses the dispatcher to delay the target action.

Calling Tick multiple times will result in on single call to the action as soon as the dispatcher of the thread that created the throttle is dispatching calls of the specified priority.

Inheritance Hierarchy
SystemObject
  TomsToolbox.DesktopDispatcherThrottle

Namespace:  TomsToolbox.Desktop
Assembly:  TomsToolbox.Desktop (in TomsToolbox.Desktop.dll) Version: 1.0.70.0
Syntax
public class DispatcherThrottle

The DispatcherThrottle type exposes the following members.

Constructors
  NameDescription
Public methodDispatcherThrottle(Action)
Initializes a new instance of the DispatcherThrottle class.
Public methodDispatcherThrottle(DispatcherPriority, Action)
Initializes a new instance of the DispatcherThrottle class.
Top
Methods
  NameDescription
Public methodTick
Ticks this instance to trigger the throttle.
Top
Extension Methods
  NameDescription
Public Extension MethodSafeCastT
Performs a cast from object to T, avoiding possible null violations if T is a value type.

[CanBeNull]

(Defined by ObjectExtensions.)
Top
See Also