Click or drag to resize

TaskManager Methods

The TaskManager type exposes the following members.

Public methodAddTask
Adds a task to a queue.
Protected methodAssertLockHeld
Throws if the current thread isn't holding any type of lock.
(Inherited from Stoppable.)
Protected methodAssertNotShuttingDown
Throws if the control is already shutting down.
(Inherited from Stoppable.)
Protected methodAssertWriteLockHeld
Throws if the current thread doesn't hold a write lock.
(Inherited from Stoppable.)
Protected methodBeginShutdownAsync
Called when shutdown was triggered.
(Overrides StoppableBeginShutdownAsync.)
Public methodCancelActiveTask
Attempts to send a cancel signal to an active task.
Public methodCancelWaitingTask
Marks a task as canceled. Throws if the task is not in the waiting state.
Public methodCancelWaitingTasks
Marks waiting tasks as canceled. Skips the task if it isn't in the waiting state.
Public methodDetachAllQueuesAsync
Detaches all queues from being processed by the manager.
Public methodDetachQueueAsync
Detaches a queue from being processed by the manager.
Public methodDispose
Dispose the object.
(Inherited from Stoppable.)
Protected methodDispose(Boolean)
Dispose implementation.
(Inherited from Stoppable.)
Protected methodEnterReadLock
Enter the lock in read mode.
(Inherited from Stoppable.)
Protected methodEnterWriteLock
Enter the lock in write mode.
(Inherited from Stoppable.)
Protected methodExitReadLock
Exit the currently held read lock.
(Inherited from Stoppable.)
Protected methodExitWriteLock
Exit the currently held write lock.
(Inherited from Stoppable.)
Public methodGetActiveTaskIds
Gets the ids of tasks currently being processed for this manager's queues, on this machine.
Public methodGetBroadcastProcessor
Gets the processor for a specific queue and broadcast type. Throws if not found.
Public methodGetDefaultBroadcastQueueId
Resolves the id of the default broadcast queue.
Public methodGetQueue
Gets a queue processor.
Public methodGetQueueIds
Gets the ids of all registered queues.
Public methodGetQueues
Gets all registered queue processors.
Public methodGetTaskProcessor
Gets the processor for a specific queue and task type. Throws if not found.
Public methodIsProcessing
Indicates whether the processing loop is running.
Public methodIsQueueRegistered
Checks if the task manager is currently processing a queue.
Public methodIsQueueShuttingDown
Checks if a queue is shutting down, or was already shutdown.
Public methodStatic memberIsSupported
Resolves whether the current environment supports the task queue.
Protected methodOnShutdownCompleted
Triggered after all shutdown operations have completed.
(Overrides StoppableOnShutdownCompleted.)
Public methodPoll
Triggers a single process cycle. Only allowed when the the task manager was created with ProcessingInterval having a value of Zero. This is primarily used for unit testing or externally driven processing intervals. This is NOT THREAD SAFE! Care should be taken so this is not called concurrently.
Public methodRegisterBroadcastProcessors
Registers the default broadcast queue with the provided processors. Opens the queue in the vault, if not done so already.
Public methodRegisterQueue
Registers a queue for the task manager to process. Opens the queue in the vault, if not done so already.
Public methodSendBroadcast(Vault, String, BroadcastDirective)
Sends a broadcast intended for the default broadcast queue.
Public methodSendBroadcast(Vault, String, String, BroadcastDirective)
Sends a broadcast.
Public methodShutdownAsync
Starts the shutdown process, if it hasn't already begun.
(Inherited from Stoppable.)
Public methodStartProcessing
Starts the processing loop in a background thread. Fails if ProcessingInterval is set to Zero. Fails if no queues are registered. The loop will automatically stop once all queues have been detatched.
Public methodTaskCancellationBroadcastHandler
Default, built-in handler for task cancellation broadcasts.
See Also