Hierarchy

Implements

Constructors

Properties

destroyed: boolean
readable: boolean
readableEncoding: null | BufferEncoding
readableEnded: boolean
readableFlowing: null | boolean
readableHighWaterMark: number
readableLength: number
readableObjectMode: boolean
writable: boolean
writableCorked: number
writableEnded: boolean
writableFinished: boolean
writableHighWaterMark: number
writableLength: number
writableObjectMode: boolean
captureRejectionSymbol: typeof captureRejectionSymbol
captureRejections: boolean

Sets or gets the default captureRejection value for all emitters.

defaultMaxListeners: number
errorMonitor: typeof errorMonitor

This symbol shall be used to install a listener for only monitoring 'error' events. Listeners installed using this symbol are called before the regular 'error' listeners are called.

Installing a listener using this symbol does not change the behavior once an 'error' event is emitted, therefore the process will still crash if no regular 'error' listener is installed.

Methods

  • Parameters

    • error: null | Error
    • callback: ((error) => void)
        • (error): void
        • Parameters

          Returns void

    Returns void

  • Parameters

    • callback: ((error?) => void)
        • (error?): void
        • Parameters

          • Optional error: null | Error

          Returns void

    Returns void

  • Parameters

    • size: number

    Returns void

  • Parameters

    • chunk: any
    • encoding: string
    • callback: ((error?) => void)
        • (error?): void
        • Parameters

          • Optional error: null | Error

          Returns void

    Returns void

  • Parameters

    • chunks: {
          chunk: any;
          encoding: string;
      }[]
    • callback: ((error?) => void)
        • (error?): void
        • Parameters

          • Optional error: null | Error

          Returns void

    Returns void

  • Event emitter The defined events on documents including:

    1. close
    2. data
    3. end
    4. error
    5. pause
    6. readable
    7. resume

    Parameters

    • event: "close"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "data"
    • listener: ((chunk) => void)
        • (chunk): void
        • Parameters

          • chunk: any

          Returns void

    Returns Duplex

  • Parameters

    • event: "end"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "error"
    • listener: ((err) => void)
        • (err): void
        • Parameters

          Returns void

    Returns Duplex

  • Parameters

    • event: "pause"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "readable"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "resume"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: string | symbol
    • listener: ((...args) => void)
        • (...args): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns Duplex

  • Returns void

  • Parameters

    Returns void

  • Parameters

    • event: "close"

    Returns boolean

  • Parameters

    • event: "data"
    • chunk: any

    Returns boolean

  • Parameters

    • event: "end"

    Returns boolean

  • Parameters

    Returns boolean

  • Parameters

    • event: "pause"

    Returns boolean

  • Parameters

    • event: "readable"

    Returns boolean

  • Parameters

    • event: "resume"

    Returns boolean

  • Parameters

    • event: string | symbol
    • Rest ...args: any[]

    Returns boolean

  • Parameters

    • Optional cb: (() => void)
        • (): void
        • Returns void

    Returns void

  • Parameters

    • chunk: any
    • Optional cb: (() => void)
        • (): void
        • Returns void

    Returns void

  • Parameters

    • chunk: any
    • Optional encoding: string
    • Optional cb: (() => void)
        • (): void
        • Returns void

    Returns void

  • Returns (string | symbol)[]

  • Returns boolean

  • Parameters

    • event: string | symbol

    Returns Function[]

  • Parameters

    • event: string | symbol
    • listener: ((...args) => void)
        • (...args): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns Duplex

  • Parameters

    • event: "close"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "data"
    • listener: ((chunk) => void)
        • (chunk): void
        • Parameters

          • chunk: any

          Returns void

    Returns Duplex

  • Parameters

    • event: "end"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "error"
    • listener: ((err) => void)
        • (err): void
        • Parameters

          Returns void

    Returns Duplex

  • Parameters

    • event: "pause"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "readable"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "resume"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: string | symbol
    • listener: ((...args) => void)
        • (...args): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns Duplex

  • Parameters

    • event: "close"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "data"
    • listener: ((chunk) => void)
        • (chunk): void
        • Parameters

          • chunk: any

          Returns void

    Returns Duplex

  • Parameters

    • event: "end"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "error"
    • listener: ((err) => void)
        • (err): void
        • Parameters

          Returns void

    Returns Duplex

  • Parameters

    • event: "pause"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "readable"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: "resume"
    • listener: (() => void)
        • (): void
        • Returns void

    Returns Duplex

  • Parameters

    • event: string | symbol
    • listener: ((...args) => void)
        • (...args): void
        • Parameters

          • Rest ...args: any[]

          Returns void

    Returns Duplex

  • Type Parameters

    Parameters

    • destination: T
    • Optional options: {
          end?: boolean;
      }
      • Optional end?: boolean

    Returns T

  • Parameters

    • chunk: any
    • Optional encoding: string

    Returns boolean

  • Parameters

    • event: string | symbol

    Returns Function[]

  • Parameters

    • Optional size: number

    Returns any

  • Returns void

  • Parameters

    Returns void

  • Parameters

    • chunk: any
    • Optional encoding: string
    • Optional cb: ((error) => void)
        • (error): void
        • Parameters

          • error: undefined | null | Error

          Returns void

    Returns boolean

  • Parameters

    • chunk: any
    • Optional cb: ((error) => void)
        • (error): void
        • Parameters

          • error: undefined | null | Error

          Returns void

    Returns boolean

  • Parameters

    • emitter: EventEmitter
    • event: string | symbol

    Returns number

    Deprecated

    since v4.0.0

  • Parameters

    Returns Promise<any[]>

  • Parameters

    Returns Promise<any[]>