X-Git-Url: https://git.piment-noir.org/?a=blobdiff_plain;ds=sidebyside;f=docs%2Fclasses%2FPoolEmitter.html;h=33034a59d7aa2c38b1cad4c6e06045bfb652e75c;hb=f4ff239c096df6dfb39c94eb3f83fd070d3d85d8;hp=a799d88becec8842dcdc3e0ec71bd3e9ba62b8b5;hpb=8d20e449d72975f6add9177d1097d5a204d14f71;p=poolifier.git diff --git a/docs/classes/PoolEmitter.html b/docs/classes/PoolEmitter.html index a799d88b..33034a59 100644 --- a/docs/classes/PoolEmitter.html +++ b/docs/classes/PoolEmitter.html @@ -1,4 +1,4 @@ -
Optional
options: EventEmitterOptionsStatic
capturev13.4.0, v12.16.0
Static
defaultname
property is set to 'MaxListenersExceededWarning&
Since
v0.11.2
Static
Readonly
error'error'
listener is installed.
v13.6.0, v12.17.0
'error'
listener is installed.
v0.1.26
v0.1.26
Symbol
s.
v6.0.0
emitter.setMaxListeners(n)
or defaults to
v1.0.0
v3.2.0
v0.1.26
v10.0.0
v0.1.101
v0.3.0
v6.0.0
v6.0.0
.once()
).
v9.4.0
v0.1.26
once('ping')
lis
v0.1.26
EventEmitter
instance. The value can be
v0.3.5
Static
getv15.2.0, v14.17.0
Static
getReturns the currently set max amount of listeners.
+For EventEmitter
s this behaves exactly the same as calling .getMaxListeners
on
+the emitter.
For EventTarget
s this is the only way to get the max event listeners for the
+event target. If the number of event handlers on a single EventTarget exceeds
+the max set, the EventTarget will print a warning.
import { getMaxListeners, setMaxListeners, EventEmitter } from 'node:events';
{
const ee = new EventEmitter();
console.log(getMaxListeners(ee)); // 10
setMaxListeners(11, ee);
console.log(getMaxListeners(ee)); // 11
}
{
const et = new EventTarget();
console.log(getMaxListeners(et)); // 10
setMaxListeners(11, et);
console.log(getMaxListeners(et)); // 11
}
+
+v19.9.0
+Static
listenerSince v3.2.0 - Use listenerCount
instead.
Static
onv13.6.0, v12.16.0
Static
oncev11.13.0, v10.16.0
Optional
options: StaticEventEmitterOptionsStatic
setv15.4.0
Generated using TypeDoc
Since
v13.4.0, v12.16.0