An object that contains an AbortSignal as the optional signal property.

Example

const controller = new AbortController()

aLongRunningOperation({
signal: controller.signal
})

// later

controller.abort()

Hierarchy

Properties

direction?: Direction

Outbound stream muxers are opened by the local node, inbound stream muxers are opened by the remote

onIncomingStream?: ((stream: Stream) => void)

Type declaration

    • (stream: Stream): void
    • A callback function invoked every time an incoming stream is opened

      Parameters

      Returns void

onStreamEnd?: ((stream: Stream) => void)

Type declaration

    • (stream: Stream): void
    • A callback function invoke every time a stream ends

      Parameters

      Returns void

signal?: AbortSignal