Abstract Class: ThreadWorker
Defined in: core/src/threads/ThreadWorker.ts:30
Provides a simple abstract interface for creating thread workers when using the ThreadPool system.
Constructors
Constructor
new ThreadWorker(
logger):ThreadWorker
Defined in: core/src/threads/ThreadWorker.ts:33
Parameters
logger
any
Returns
ThreadWorker
Properties
logger
protectedlogger:any
Defined in: core/src/threads/ThreadWorker.ts:31
Methods
onMessage()
abstractonMessage(msg):void|Promise<void>
Defined in: core/src/threads/ThreadWorker.ts:42
Callback function when a message is received from the thread pool manager.
Parameters
msg
The message that was received.
Returns
void | Promise<void>
start()
abstractstart():void|Promise<void>
Defined in: core/src/threads/ThreadWorker.ts:47
Starts execution of the thread worker.
Returns
void | Promise<void>
stop()
abstractstop():void|Promise<void>
Defined in: core/src/threads/ThreadWorker.ts:52
Stops execution of all work and shuts down the thread worker.
Returns
void | Promise<void>