X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=src%2Futility-types.ts;h=f13cce6a70d9f60ed7417b9d2a45675c5179fb72;hb=627fc572465ba2113cbf3df6bd055c3242ecd0fe;hp=aa4e219853caba926bc74867a2089827f6f69765;hpb=95d1a734d57942c892202df7c0fcaf2fb5ab89ab;p=poolifier.git diff --git a/src/utility-types.ts b/src/utility-types.ts index aa4e2198..f13cce6a 100644 --- a/src/utility-types.ts +++ b/src/utility-types.ts @@ -7,7 +7,6 @@ import type { KillBehavior } from './worker/worker-options.js' /** * Worker error. - * * @typeParam Data - Type of data sent to the worker triggering an error. This can only be structured-cloneable data. */ export interface WorkerError { @@ -27,7 +26,6 @@ export interface WorkerError { /** * Task performance. - * * @internal */ export interface TaskPerformance { @@ -51,7 +49,6 @@ export interface TaskPerformance { /** * Worker task performance statistics computation settings. - * * @internal */ export interface WorkerStatistics { @@ -67,27 +64,24 @@ export interface WorkerStatistics { /** * Task function properties. - * - * @internal */ export interface TaskFunctionProperties { /** * Task function name. */ - name: string + readonly name: string /** * Task function priority. Lower values have higher priority. */ - priority?: number + readonly priority?: number /** * Task function worker choice strategy. */ - strategy?: WorkerChoiceStrategy + readonly strategy?: WorkerChoiceStrategy } /** * Message object that is passed as a task between main worker and worker. - * * @typeParam Data - Type of data sent to the worker. This can only be structured-cloneable data. * @internal */ @@ -102,7 +96,6 @@ export interface Task { readonly data?: Data /** * Task priority. Lower values have higher priority. - * * @defaultValue 0 */ readonly priority?: number @@ -126,7 +119,6 @@ export interface Task { /** * Message object that is passed between main worker and worker. - * * @typeParam Data - Type of data sent to the worker or execution response. This can only be structured-cloneable data. * @typeParam ErrorData - Type of data sent to the worker triggering an error. This can only be structured-cloneable data. * @internal @@ -192,7 +184,6 @@ export interface MessageValue /** * An object holding the task execution response promise resolve/reject callbacks. - * * @typeParam Response - Type of execution response. This can only be structured-cloneable data. * @internal */