X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;f=docs%2Fclasses%2FAbstractWorker.html;h=c3a79eecdf9d5a71e8b0258e53321f43a4f97bbf;hb=4cb259d3e1837759b8bac901d3755f1610b5ddc4;hp=3897c5873d3bb7117d1d6df1b8f5065ea624d1e8;hpb=08e40091fb1d27284ffcdfaced81292139a02c55;p=poolifier.git diff --git a/docs/classes/AbstractWorker.html b/docs/classes/AbstractWorker.html index 3897c587..c3a79eec 100644 --- a/docs/classes/AbstractWorker.html +++ b/docs/classes/AbstractWorker.html @@ -1,13 +1,13 @@ -AbstractWorker | poolifier - v2.6.13
+AbstractWorker | poolifier - v2.6.42
-
+
  • The search index is not available
  • poolifier - v2.6.42 +
    @@ -47,63 +47,69 @@
  • ClusterWorker
  • ThreadWorker
  • +
  • Defined in src/worker/abstract-worker.ts:49
  • - +

    Constructors

    - +
      - +
    • Constructs a new poolifier worker.

      @@ -111,7 +117,7 @@

      Type Parameters

      • -

        MainWorker extends Worker | MessagePort

      • +

        MainWorker extends MessagePort | Worker

      • Data = unknown

      • @@ -130,17 +136,17 @@
  • -
    taskFunctions: WorkerFunction<Data, Response> | TaskFunctions<Data, Response>
    -

    Task function(s) processed by the worker when the pool's execution function is invoked. The first function is the default function.

    +
    mainWorker: MainWorker
    +

    Reference to main worker.

  • -
    mainWorker: MainWorker
    -

    Reference to main worker.

    +
    taskFunctions: TaskFunction<Data, Response> | TaskFunctions<Data, Response>
    +

    Task function(s) processed by the worker when the pool's execution function is invoked. The first function is the default function.

  • -
    opts: WorkerOptions = ...
    +
    opts: WorkerOptions = DEFAULT_WORKER_OPTIONS

    Options for the worker.

  • @@ -148,17 +154,17 @@
    +
  • Defined in src/worker/abstract-worker.ts:83
  • Properties

    -
    - -
    aliveInterval?: Timeout
    -

    Handler id of the aliveInterval worker alive check.

    +
    + +
    activeInterval?: Timeout
    +

    Handler id of the activeInterval worker activity check.

    +
  • Defined in src/worker/abstract-worker.ts:73
  • id: number
    @@ -166,7 +172,7 @@
    +
  • Defined in src/worker/abstract-worker.ts:57
  • isMain: boolean
    @@ -174,7 +180,7 @@
    +
  • Defined in src/worker/abstract-worker.ts:85
  • lastTaskTimestamp: number
    @@ -182,23 +188,23 @@
    -
    - +
  • Defined in src/worker/abstract-worker.ts:65
  • +
    +
    mainWorker: MainWorker

    Reference to main worker.

    +
  • Defined in src/worker/abstract-worker.ts:86
  • - -
    opts: WorkerOptions = ...
    + +
    opts: WorkerOptions = DEFAULT_WORKER_OPTIONS

    Options for the worker.

    +
  • Defined in src/worker/abstract-worker.ts:88
  • statistics: WorkerStatistics
    @@ -206,15 +212,15 @@
    +
  • Defined in src/worker/abstract-worker.ts:69
  • -
    taskFunctions: Map<string, WorkerFunction<Data, Response>>
    +
    taskFunctions: Map<string, TaskFunction<Data, Response>>

    Task function(s) processed by the worker when the pool's execution function is invoked.

    +
  • Defined in src/worker/abstract-worker.ts:61
  • Methods

    @@ -234,21 +240,21 @@ If a task function with the same name already exists, it is replaced.

  • -
    fn: WorkerFunction<Data, Response>
    +
    fn: TaskFunction<Data, Response>

    The task function to add.

  • Returns boolean

    Whether the task function was added or not.

    -

    Throws

    https://nodejs.org/api/errors.html#class-typeerror If the name parameter is not a string.

    +

    Throws

    https://nodejs.org/api/errors.html#class-typeerror If the name parameter is not a string or an empty string.

    Throws

    https://nodejs.org/api/errors.html#class-error If the name parameter is the default task function reserved name.

    Throws

    https://nodejs.org/api/errors.html#class-typeerror If the fn parameter is not a function.

    +
  • Defined in src/worker/abstract-worker.ts:193
  • +
  • Defined in node_modules/.pnpm/@types+node@20.5.9/node_modules/@types/node/async_hooks.d.ts:306
  • Returns TaskPerformance

    +
  • Defined in src/worker/abstract-worker.ts:576
  • -
    - +
  • Defined in node_modules/.pnpm/@types+node@20.5.9/node_modules/@types/node/async_hooks.d.ts:283
  • +
    +
    +
  • Defined in src/worker/abstract-worker.ts:419
  • +
    + +
    +
  • Defined in src/worker/abstract-worker.ts:600
  • +
    + +
    +
  • Defined in src/worker/abstract-worker.ts:132
  • +
    + +

    Returns void

    +
  • Defined in src/worker/abstract-worker.ts:101
  • +
  • Defined in node_modules/.pnpm/@types+node@20.5.9/node_modules/@types/node/async_hooks.d.ts:302
  • Returns TaskPerformance

    +
  • Defined in src/worker/abstract-worker.ts:585
  • -
    - -
    +
  • Defined in src/worker/abstract-worker.ts:434
  • +
  • Defined in src/worker/abstract-worker.ts:466
  • +
    + +
    +
    + +
    +
  • Defined in src/worker/abstract-worker.ts:177
  • +
    + +
    +
  • Defined in src/worker/abstract-worker.ts:329
  • +
  • Defined in src/worker/abstract-worker.ts:231
  • +
  • Defined in src/worker/abstract-worker.ts:476
  • +
  • Defined in src/worker/abstract-worker.ts:541
  • +
  • Defined in node_modules/.pnpm/@types+node@20.5.9/node_modules/@types/node/async_hooks.d.ts:294
  • +
  • Defined in src/worker/abstract-worker.ts:504
  • +
    + +
    +
  • Defined in src/worker/abstract-worker.ts:446
  • -
    - +
  • Defined in src/worker/abstract-worker.ts:285
  • +
    +
    -
    - +
  • Defined in src/worker/abstract-worker.ts:398
  • +
    +
    +
  • Defined in src/worker/abstract-worker.ts:409
  • -
    - -
    +
    + +
    +
  • Defined in src/worker/abstract-worker.ts:606
  • +
  • Defined in node_modules/.pnpm/@types+node@20.5.9/node_modules/@types/node/async_hooks.d.ts:277
  • @@ -770,11 +863,11 @@ then restore the original execution context.

    +
    -

    Generated using TypeDoc

    -
    \ No newline at end of file +

    Generated using TypeDoc

    +
    \ No newline at end of file