Interface TaskRunner
Allows you to request a thread execute the associated Task.
Namespace: Apache.NMS.ActiveMQ.Threads
Assembly: Apache.NMS.ActiveMQ.dll
Syntax
public interface TaskRunner
Methods
| Improve this Doc View SourceShutdown()
Attempt to Shutdown the TaskRunner, this method will wait indefinitely for the TaskRunner to quite if the task runner is in a call to its Task's run method and that never returns.
Declaration
void Shutdown()
Shutdown(TimeSpan)
Performs a timed wait for the TaskRunner to shutdown. If the TaskRunner is in a call to its Task's run method and that does not return before the timeout expires this method returns and the TaskRunner may remain in the running state.
Declaration
void Shutdown(TimeSpan timeout)
Parameters
Type | Name | Description |
---|---|---|
System.TimeSpan | timeout | A System.TimeSpan |
ShutdownWithAbort(TimeSpan)
Performs a timed wait for the TaskRunner to shutdown. If the TaskRunner is in a call to its Task's run method and that does not return before the timeout expires this method sends an Abort to the Task thread and return.
Declaration
void ShutdownWithAbort(TimeSpan timeout)
Parameters
Type | Name | Description |
---|---|---|
System.TimeSpan | timeout | A System.TimeSpan |
Wakeup()
Wakeup the TaskRunner and have it check for any pending work that needs to be completed. If none is found it will go back to sleep until another Wakeup call is made.
Declaration
void Wakeup()