X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Fpools%2Fworker.ts;h=b3e02f3ceb5ce8631848e65fcfcba871c4dd9e3c;hb=a4a88903255bd661b57480ce9b07dd2f2962f069;hp=03cecce849a2cb9d71ad04a566795d3588238509;hpb=776e97a2d35ba2003ddeddecc826353b569a4344;p=poolifier.git diff --git a/src/pools/worker.ts b/src/pools/worker.ts index 03cecce8..b3e02f3c 100644 --- a/src/pools/worker.ts +++ b/src/pools/worker.ts @@ -4,11 +4,15 @@ import type { Task } from '../utility-types' /** * Callback invoked when the worker has started successfully. + * + * @typeParam Worker - Type of worker. */ export type OnlineHandler = (this: Worker) => void /** * Callback invoked if the worker has received a message. + * + * @typeParam Worker - Type of worker. */ export type MessageHandler = ( this: Worker, @@ -17,6 +21,8 @@ export type MessageHandler = ( /** * Callback invoked if the worker raised an error. + * + * @typeParam Worker - Type of worker. */ export type ErrorHandler = ( this: Worker, @@ -25,6 +31,8 @@ export type ErrorHandler = ( /** * Callback invoked when the worker exits successfully. + * + * @typeParam Worker - Type of worker. */ export type ExitHandler = ( this: Worker,