Dispatcher Members

Microsoft Robotics Class Reference

The Dispatcher type exposes the following members.

Constructors

  Name Description
Public method Dispatcher() () () ()
Constructs a Dispatcher instance using the default number of threads and no friendly tag
Public method Dispatcher(Int32, String)
Constructs a Dispatcher instance. The instance is usable only after AddPort is called at least once
Public method Dispatcher(Int32, ThreadPriority, DispatcherOptions, String)
Constructs a Dispatcher instance. The instance is usable only after AddPort is called at least once
Public method Dispatcher(Int32, ThreadPriority, Boolean, String)
Constructs a Dispatcher instance. The instance is usable only after AddPort is called at least once
Public method Dispatcher(Int32, ThreadPriority, DispatcherOptions, ApartmentState, String)
Constructs a Dispatcher instance. The instance is usable only after AddPort is called at least once
Public method Dispatcher(Int32, ThreadPriority, DispatcherOptions, ApartmentState, Int32, String)
Constructs a Dispatcher instance. The instance is usable only after AddPort is called at least once

Methods

  Name Description
Public methodStatic member AddCausality
Adds a causality to the current thread causality stack
Public methodStatic member AddCausalityBreak
Adds a causality with BreakOnReceive = true to the current thread causality stack. In a debug build, if a debugger is attached this will cause the debugger to break just before the any task in this causality is executed.
Public methodStatic member ClearCausalities
Removes all causalities from current thread context
Public method Dispose
Stops all scheduling and disposes this dispatcher instance
Public method Equals
Determines whether the specified Object is equal to the current Object.
(Inherited from Object.)
Protected method Finalize
Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
(Inherited from Object.)
Public method GetHashCode
Serves as a hash function for a particular type.
(Inherited from Object.)
Public method GetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected method MemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodStatic member RemoveCausality(String)
Removes a causality from the current thread context
Public methodStatic member RemoveCausality(ICausality)
Removes a causality from the current thread context
Public method ToString
Returns a String that represents the current Object.
(Inherited from Object.)

Properties

  Name Description
Public propertyStatic member ActiveCausalities
Retrieves a collection of all the bottom of the stack causalities that would be responsible for capturing exceptions in the current context
Public property DispatcherQueues
Collection of task ports associated with this dispatcher instance
Public propertyStatic member HasActiveCausalities
True indicates that one or more causality is active on the current thread context
Public property Name
Friendly name associated with this dispatcher instance
Public property Options
Dispatcher configuration options
Public property PendingTaskCount
Number of pending tasks across all dispatcher ports associated to this dispatcher
Public property ProcessedTaskCount
Monotonically increasing counter indicating total number of task processed so far
Public propertyStatic member ThreadsPerCpu
Number of threads per Cpu, if threads are not specified when initializing the dispatcher
Public property UnhandledExceptionPort
Gets or sets a port that any unhandled exceptions occuring in tasks running in threads owned by this dispatcher will be sent to.
Public property WorkerThreadCount
Number of worker threads processing tasks across all dispatcher ports associated with this dispatcher

Events

  Name Description
Public event UnhandledException
This event is raised when an unhandled exception occurs in tasks running in threads owned by this dispatcher.

See Also

Dispatcher Class

Microsoft.Ccr.Core Namespace