From: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Date: Sun, 16 Apr 2023 11:03:48 +0000 (+0000)
Subject: chore: generate documentation
X-Git-Tag: v2.4.11~41
X-Git-Url: https://git.piment-noir.org/?a=commitdiff_plain;h=3bd6a82e43e11294af91bbd19647944ac740169e;p=poolifier.git
chore: generate documentation
---
diff --git a/docs/assets/main.js b/docs/assets/main.js
index d9b2d0a67..932e185d5 100644
--- a/docs/assets/main.js
+++ b/docs/assets/main.js
@@ -1,7 +1,7 @@
"use strict";
-"use strict";(()=>{var Se=Object.create;var re=Object.defineProperty;var we=Object.getOwnPropertyDescriptor;var Te=Object.getOwnPropertyNames;var ke=Object.getPrototypeOf,Qe=Object.prototype.hasOwnProperty;var Pe=(t,e)=>()=>(e||t((e={exports:{}}).exports,e),e.exports);var Ie=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Te(e))!Qe.call(t,i)&&i!==r&&re(t,i,{get:()=>e[i],enumerable:!(n=we(e,i))||n.enumerable});return t};var Ce=(t,e,r)=>(r=t!=null?Se(ke(t)):{},Ie(e||!t||!t.__esModule?re(r,"default",{value:t,enumerable:!0}):r,t));var ae=Pe((se,oe)=>{(function(){var t=function(e){var r=new t.Builder;return r.pipeline.add(t.trimmer,t.stopWordFilter,t.stemmer),r.searchPipeline.add(t.stemmer),e.call(r,r),r.build()};t.version="2.3.9";t.utils={},t.utils.warn=function(e){return function(r){e.console&&console.warn&&console.warn(r)}}(this),t.utils.asString=function(e){return e==null?"":e.toString()},t.utils.clone=function(e){if(e==null)return e;for(var r=Object.create(null),n=Object.keys(e),i=0;i Chooses a worker node for the next task. The default uses a round robin algorithm to distribute the load. [worker node key, worker node]. Creates a new worker and sets it up completely in the pool worker nodes. New, completely set up worker. Returns a newly created worker. Shutdowns every current worker in this pool. Implementation of IPool.destroy Implementation of IPool.destroy=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;l=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),l=0;lReturns void
-
-Protected choose
-
+
Returns
Returns [number, WorkerNode<Worker, Data>]
Returns [number, WorkerNode<Worker, Data>]
-
-Protected create
-
+
Returns
Returns Worker
Returns Worker
-
-Protected Abstract create
-
+
Returns Worker
Returns Worker
-
-Private dequeue
-
+
+Parameters
workerNodeKey: number
Returns undefined | Task<Data>
workerNodeKey: number
Returns undefined | Task<Data>
-
destroy
-
-
+
Returns Promise<void>
Returns Promise<void>
-
-Protected Abstract destroy
A worker within workerNodes.
Enables/disables the worker tasks queue in this pool.
Whether to enable or disable the worker tasks queue.
Optional tasksQueueOptions: TasksQueueOptionsOptional tasksQueueOptions: TasksQueueOptionsThe worker tasks queue options.
Implementation of IPool.enableTasksQueue
+Implementation of IPool.enableTasksQueue
Private enqueueExecutes the function specified in the worker constructor with the task data input parameter.
@@ -544,32 +544,32 @@ Can be overridden.Optional data: DataOptional data: DataThe task input data for the specified worker function. This can only be serializable data.
Implementation of IPool.execute
+Implementation of IPool.execute
Private executeFinds a free worker node key based on the number of tasks the worker has applied.
If a worker is found with 0 running tasks, it is detected as free and its worker node key is returned.
A worker node key if there is one, -1 otherwise.
Implementation of IPool.findFreeWorkerNodeKey
+Implementation of IPool.findFreeWorkerNodeKey
Private flushPrivate flushPrivate flushPrivate getGets the given worker its worker node key.
@@ -628,16 +628,16 @@ Can be overridden.The worker.
Private getGets the given worker its tasks usage in the pool.
@@ -649,34 +649,34 @@ Can be overridden.The worker.
Protected internalProtected Abstract isShould return whether the worker is the main worker or not.
Private pushPushes the given worker in the pool worker nodes.
@@ -686,16 +686,16 @@ Can be overridden.The worker.
Protected Abstract registerThe worker which should register a listener.
The message listener callback.
Private removeRemoves the given worker from the pool worker nodes.
The worker.
Protected Abstract sendSends a message to the given worker.
The worker which should receive the message.
The message.
Sets the worker tasks queue options in this pool.
The worker tasks queue options.
Implementation of IPool.setTasksQueueOptions
+Implementation of IPool.setTasksQueueOptions
Sets the worker choice strategy in this pool.
The worker choice strategy.
Optional workerChoiceStrategyOptions: WorkerChoiceStrategyOptionsOptional workerChoiceStrategyOptions: WorkerChoiceStrategyOptionsThe worker choice strategy options.
Implementation of IPool.setWorkerChoiceStrategy
+Implementation of IPool.setWorkerChoiceStrategy
Sets the worker choice strategy options in this pool.
The worker choice strategy options.
Implementation of IPool.setWorkerChoiceStrategyOptions
+Implementation of IPool.setWorkerChoiceStrategyOptions
Private setSets the given worker in the pool worker nodes.
The worker node key.
The worker.
The worker tasks usage.
The worker task queue.
Private setSets the given worker node its tasks usage in the pool.
The worker node.
The worker node tasks usage.
Protected setupSetup hook to execute code before worker node are created in the abstract constructor. Can be overridden
Private tasksProtected workerThis function is the listener registered for each worker message.
The listener function to execute when a message is received from a worker.
This function is the listener registered for each worker message.
@@ -922,10 +922,10 @@ Can be overriddenGenerated using TypeDoc
Generated using TypeDoc
Overrides Array.concat
Returns the this object after copying a section of the array identified by start and end to the same array starting at position target
@@ -225,46 +225,46 @@ to the same array starting at position targetIf target is negative, it is treated as length+target where length is the length of the array.
If start is negative, it is treated as length+start. If end is negative, it is treated as length+end.
Optional end: numberOptional end: numberIf not specified, length of the this object is used as its default value.
Inherited from Array.copyWithin
Returns an iterable of key, value pairs for every entry in the array
Inherited from Array.entries
A function that accepts up to three arguments. The every method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value false, or until the end of the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.every
Determines whether all the members of an array satisfy the specified test.
A function that accepts up to three arguments. The every method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value false, or until the end of the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.every
Changes all array elements from start to end index to a static value and returns the modified array
value to fill array section with
Optional start: numberOptional start: numberindex to start filling the array at. If start is negative, it is treated as length+start where length is the length of the array.
Optional end: numberOptional end: numberindex to stop filling the array at. If end is negative, it is treated as length+end.
Inherited from Array.fill
A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.filter
Returns the elements of an array that meet the condition specified in a callback function.
A function that accepts up to three arguments. The filter method calls the predicate function one time for each element in the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.filter
Returns the value of the first element in the array where predicate is true, and undefined otherwise.
@@ -459,72 +459,72 @@ otherwise.find calls predicate once for each element of the array, in ascending order, until it finds one where predicate returns true. If such an element is found, find immediately returns that element value. Otherwise, find returns undefined.
Optional thisArg: anyOptional thisArg: anyIf provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.
Inherited from Array.find
Optional thisArg: anyOptional thisArg: anyInherited from Array.find
Returns the index of the first element in the array where predicate is true, and -1 otherwise.
@@ -533,28 +533,28 @@ otherwise.find calls predicate once for each element of the array, in ascending order, until it finds one where predicate returns true. If such an element is found, findIndex immediately returns that element index. Otherwise, findIndex returns -1.
Optional thisArg: anyOptional thisArg: anyIf provided, it will be used as the this value for each invocation of predicate. If it is not provided, undefined is used instead.
Inherited from Array.findIndex
Returns a new array with all sub-array elements concatenated into it recursively up to the specified depth.
@@ -574,26 +574,26 @@ specified depth.Optional depth: DOptional depth: DThe maximum recursion depth
Inherited from Array.flat
Calls a defined callback function on each element of an array. Then, flattens the result into a new array. @@ -603,47 +603,47 @@ This is identical to a map followed by flat with depth 1.
A function that accepts up to three arguments. The flatMap method calls the callback function one time for each element in the array.
Optional thisArg: ThisOptional thisArg: ThisAn object to which the this keyword can refer in the callback function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.flatMap
Performs the specified action for each element in an array.
A function that accepts up to three arguments. forEach calls the callbackfn function one time for each element in the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.forEach
Determines whether an array includes a certain element, returning true or false as appropriate.
The element to search for.
Optional fromIndex: numberOptional fromIndex: numberThe position in this array at which to begin searching for searchElement.
Inherited from Array.includes
Returns the index of the first occurrence of a value in an array, or -1 if it is not present.
The value to locate in the array.
Optional fromIndex: numberOptional fromIndex: numberThe array index at which to begin the search. If fromIndex is omitted, the search starts at index 0.
Inherited from Array.indexOf
Adds all the elements of an array into a string, separated by the specified separator string.
Optional separator: stringOptional separator: stringA string used to separate one element of the array from the next in the resulting string. If omitted, the array elements are separated with a comma.
Inherited from Array.join
Returns the index of the last occurrence of a specified value in an array, or -1 if it is not present.
The value to locate in the array.
Optional fromIndex: numberOptional fromIndex: numberThe array index at which to begin searching backward. If fromIndex is omitted, the search starts at the last index in the array.
Inherited from Array.lastIndexOf
A function that accepts up to three arguments. The map method calls the callbackfn function one time for each element in the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the callbackfn function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.map
Removes the last element from an array and returns it. If the array is empty, undefined is returned and the array is not modified.
Inherited from Array.pop
Overrides Array.push
Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.
A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.
Inherited from Array.reduce
Inherited from Array.reduce
Calls the specified callback function for all the elements in an array. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.
A function that accepts up to four arguments. The reduce method calls the callbackfn function one time for each element in the array.
If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.
Inherited from Array.reduce
Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.
A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.
Inherited from Array.reduceRight
Inherited from Array.reduceRight
Calls the specified callback function for all the elements in an array, in descending order. The return value of the callback function is the accumulated result, and is provided as an argument in the next call to the callback function.
A function that accepts up to four arguments. The reduceRight method calls the callbackfn function one time for each element in the array.
If initialValue is specified, it is used as the initial value to start the accumulation. The first call to the callbackfn function provides this value as an argument instead of an array value.
Inherited from Array.reduceRight
Removes the first element from an array and returns it. If the array is empty, undefined is returned and the array is not modified.
Inherited from Array.shift
Returns a copy of a section of an array. For both start and end, a negative index can be used to indicate an offset from the end of the array. @@ -1110,23 +1110,23 @@ For example, -2 refers to the second to last element of the array.
Optional start: numberOptional start: numberThe beginning index of the specified portion of the array. If start is undefined, then the slice begins at index 0.
Optional end: numberOptional end: numberThe end index of the specified portion of the array. This is exclusive of the element at the index 'end'. If end is undefined, then the slice extends to the end of the array.
Inherited from Array.slice
Determines whether the specified callback function returns true for any element of an array.
A function that accepts up to three arguments. The some method calls the predicate function for each element in the array until the predicate returns a value which is coercible to the Boolean value true, or until the end of the array.
Optional thisArg: anyOptional thisArg: anyAn object to which the this keyword can refer in the predicate function. If thisArg is omitted, undefined is used as the this value.
Inherited from Array.some
Sorts an array in place. This method mutates the array and returns a reference to the same array.
@@ -1175,7 +1175,7 @@ This method mutates the array and returns a reference to the same array.Optional compareFn: ((a: T, b: T) => number)Optional compareFn: ((a, b) => number)Function used to determine the order of the elements. It is expected to return a negative value if the first argument is less than the second argument, zero if they're equal, and a positive value otherwise. If omitted, the elements are sorted in ascending, ASCII character order.
@@ -1184,43 +1184,43 @@ value otherwise. If omitted, the elements are sorted in ascending, ASCII charactInherited from Array.sort
Optional deleteCount: numberOptional deleteCount: numberRest ...items: T[]Rest ...items: T[]Overrides Array.splice
Returns a string representation of an array. The elements are converted to string using their toLocaleString methods.
Inherited from Array.toLocaleString
Overrides Array.unshift
Static fromAn array-like object to convert to an array.
Inherited from Array.from
Creates an array from an iterable object.
An array-like object to convert to an array.
A mapping function to call on every element of the array.
Optional thisArg: anyOptional thisArg: anyValue of 'this' used to invoke the mapfn.
Inherited from Array.from
Creates an array from an iterable object.
An iterable object to convert to an array.
Inherited from Array.from
Creates an array from an iterable object.
An iterable object to convert to an array.
A mapping function to call on every element of the array.
Optional thisArg: anyOptional thisArg: anyValue of 'this' used to invoke the mapfn.
Inherited from Array.from
Static isStatic ofRest ...items: T[]Rest ...items: T[]A set of elements to include in the new array object.
Inherited from Array.of
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Inherited from EventEmitter.once
Adds the listener function to the beginning of the listeners array for the
event named eventName. No checks are made to see if the listener has
@@ -381,32 +381,32 @@ times.
The name of the event.
The callback function
Rest ...args: any[]Rest ...args: any[]Inherited from EventEmitter.prependListener
Adds a one-timelistener function for the event named eventName to the beginning of the listeners array. The next time eventName is triggered, this
listener is removed, and then invoked.
The name of the event.
The callback function
Rest ...args: any[]Rest ...args: any[]Inherited from EventEmitter.prependOnceListener
Returns a copy of the array of listeners for the event named eventName,
including any wrappers (such as those created by .once()).
.once()).
Inherited from EventEmitter.rawListeners
Removes all listeners, or those of the specified eventName.
It is bad practice to remove listeners added elsewhere in the code, @@ -480,15 +480,15 @@ component or module (e.g. sockets or file streams).
Optional event: string | symbolOptional event: string | symbolInherited from EventEmitter.removeAllListeners
Removes the specified listener from the listener array for the event namedeventName.
const callback = (stream) => {
console.log('someone connected!');
};
server.on('connection', callback);
// ...
server.removeListener('connection', callback);
@@ -520,28 +520,28 @@ recently added instance. In the example the once('ping')lis
Parameters
-
-
eventName: string | symbol
+eventName: string | symbol
-
-
listener: ((...args: any[]) => void)
+listener: ((...args) => void)
-
-
-- (...args: any[]): void
+
+- (...args): void
-
Parameters
-
-
Rest ...args: any[]
+Rest ...args: any[]
Inherited from EventEmitter.removeListener
By default EventEmitters will print a warning if more than 10 listeners are
added for a particular event. This is a useful default that helps finding
@@ -555,15 +555,15 @@ modified for this specific EventEmitter instance. The value can be
Inherited from EventEmitter.setMaxListeners
Static getReturns a copy of the array of listeners for the event named eventName.
For EventEmitters this behaves exactly the same as calling .listeners on
@@ -579,17 +579,17 @@ event target. This is useful for debugging and diagnostic purposes.
Inherited from EventEmitter.getEventListeners
Static listenerA class method that returns the number of listeners for the given eventNameregistered on the given emitter.
const { EventEmitter, listenerCount } = require('events');
const myEmitter = new EventEmitter();
myEmitter.on('event', () => {});
myEmitter.on('event', () => {});
console.log(listenerCount(myEmitter, 'event'));
// Prints: 2
@@ -603,21 +603,21 @@ event target. This is useful for debugging and diagnostic purposes.
Parameters
-
-
emitter: EventEmitter
+emitter: EventEmitter
The emitter to query
-
-
eventName: string | symbol
+eventName: string | symbol
The event name
Inherited from EventEmitter.listenerCount
Static onconst { on, EventEmitter } = require('events');
(async () => {
const ee = new EventEmitter();
// Emit later on
process.nextTick(() => {
ee.emit('foo', 'bar');
ee.emit('foo', 42);
});
for await (const event of on(ee, 'foo')) {
// The execution of this inner block is synchronous and it
// processes one event at a time (even with await). Do not use
// if concurrent execution is required.
console.log(event); // prints ['bar'] [42]
}
// Unreachable here
})();
@@ -637,21 +637,21 @@ composed of the emitted event arguments.
The name of the event being listened for
Optional options: StaticEventEmitterOptionsOptional options: StaticEventEmitterOptionsInherited from EventEmitter.on
Static onceCreates a Promise that is fulfilled when the EventEmitter emits the given
event or that is rejected if the EventEmitter emits 'error' while waiting.
@@ -676,34 +676,34 @@ special handling:
Optional options: StaticEventEmitterOptionsOptional options: StaticEventEmitterOptionsInherited from EventEmitter.once
Optional options: StaticEventEmitterOptionsOptional options: StaticEventEmitterOptionsInherited from EventEmitter.once
Static setconst {
setMaxListeners,
EventEmitter
} = require('events');
const target = new EventTarget();
const emitter = new EventEmitter();
setMaxListeners(5, target, emitter);
@@ -714,11 +714,11 @@ special handling:
Optional n: numberOptional n: numberA non-negative number. The maximum number of listeners per EventTarget event.
Rest ...eventTargets: (EventEmitter | _DOMEventTarget)[]Rest ...eventTargets: (EventEmitter | _DOMEventTarget)[]Inherited from EventEmitter.setMaxListeners
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Finds a free worker node key based on the number of tasks the worker has applied.
@@ -158,16 +158,16 @@Sets the worker tasks queue options in this pool.
The worker tasks queue options.
Sets the worker choice strategy in this pool.
The worker choice strategy.
Optional workerChoiceStrategyOptions: WorkerChoiceStrategyOptionsOptional workerChoiceStrategyOptions: WorkerChoiceStrategyOptionsThe worker choice strategy options.
Sets the worker choice strategy options in this pool.
The worker choice strategy options.
Readonly typePool type.
If it is 'dynamic', it provides the max property.
Readonly workerPool worker nodes.
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Readonly workerThe worker handling the execution.
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Optional data: DataGenerated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Generated using TypeDoc
Type of worker which manages this pool.