Options
All
  • Public
  • Public/Protected
  • All
Menu

Class LoggingSinkNode<In>

This sink node will serialize the data frames pushed to this output layer, and log them to the console using the logging function specified in the constructor.

Type parameters

Hierarchy

Index

Constructors

constructor

Properties

callback

callback: (frame: In | In[], options?: PushOptions) => void | Promise<void>

Type declaration

    • (frame: In | In[], options?: PushOptions): void | Promise<void>
    • Parameters

      Returns void | Promise<void>

graph

graph: any

Graph shape

name

name: string

Name of the node. Does not have to be unique.

Protected options

uid

uid: string = ...

Unique identifier of node.

Readonly Static captureRejectionSymbol

captureRejectionSymbol: typeof captureRejectionSymbol

Static captureRejections

captureRejections: boolean

Sets or gets the default captureRejection value for all emitters.

Static defaultMaxListeners

defaultMaxListeners: number

Readonly Static errorMonitor

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.

Accessors

inlets

  • get inlets(): Inlet<In>[]

model

  • get model(): Model<any, any>
  • Graph this model is part of

    Returns Model<any, any>

    Positioning model

outlets

  • get outlets(): Outlet<Out>[]

Methods

addListener

  • addListener(event: string | symbol, listener: (...args: any[]) => void): LoggingSinkNode<In>
  • Parameters

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

          • Rest ...args: any[]

          Returns void

    Returns LoggingSinkNode<In>

emit

  • emit(name: string | symbol, ...args: any[]): boolean
  • emit(event: "available"): boolean
  • emit(name: "completed", e: PushCompletedEvent): boolean
  • emit(name: "error", e: PushError): boolean
  • emit(name: "ready"): boolean
  • emit(name: "destroy"): boolean

emitAsync

  • emitAsync(type: string | symbol, ...args: any[]): Promise<boolean>

eventNames

  • eventNames(): (string | symbol)[]

getMaxListeners

  • getMaxListeners(): number

getOptions

isAvailable

  • isAvailable(): boolean

isReady

  • isReady(): boolean

listenerCount

  • listenerCount(type: string | symbol): number
  • Parameters

    • type: string | symbol

    Returns number

listeners

  • listeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

logger

  • logger(level: string, log: any): void

off

  • off(event: string | symbol, listener: (...args: any[]) => void): LoggingSinkNode<In>
  • Parameters

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

          • Rest ...args: any[]

          Returns void

    Returns LoggingSinkNode<In>

on

onPush

  • onPush(frame: In, options?: PushOptions): Promise<void>

once

onceAvailable

  • onceAvailable(): Promise<void>

onceCompleted

  • onceCompleted(frameUID: string): Promise<PushEvent>

Protected persistDataObject

  • persistDataObject(frame: In): Promise<void>

prependListener

  • prependListener(event: string | symbol, listener: (...args: any[]) => void): LoggingSinkNode<In>
  • Parameters

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

          • Rest ...args: any[]

          Returns void

    Returns LoggingSinkNode<In>

prependOnceListener

  • prependOnceListener(event: string | symbol, listener: (...args: any[]) => void): LoggingSinkNode<In>
  • Parameters

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

          • Rest ...args: any[]

          Returns void

    Returns LoggingSinkNode<In>

pull

push

  • push(data: In | In[], options?: PushOptions): Promise<void>

rawListeners

  • rawListeners(event: string | symbol): Function[]
  • Parameters

    • event: string | symbol

    Returns Function[]

removeAllListeners

removeListener

  • removeListener(event: string | symbol, listener: (...args: any[]) => void): LoggingSinkNode<In>
  • Parameters

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

          • Rest ...args: any[]

          Returns void

    Returns LoggingSinkNode<In>

setMaxListeners

setOptions

Static listenerCount

  • listenerCount(emitter: EventEmitter, event: string | symbol): number
  • deprecated

    since v4.0.0

    Parameters

    • emitter: EventEmitter
    • event: string | symbol

    Returns number

Static on

  • on(emitter: EventEmitter, event: string): AsyncIterableIterator<any>
  • Parameters

    • emitter: EventEmitter
    • event: string

    Returns AsyncIterableIterator<any>

Static once

  • once(emitter: NodeEventTarget, event: string | symbol): Promise<any[]>
  • once(emitter: DOMEventTarget, event: string): Promise<any[]>
  • Parameters

    • emitter: NodeEventTarget
    • event: string | symbol

    Returns Promise<any[]>

  • Parameters

    • emitter: DOMEventTarget
    • event: string

    Returns Promise<any[]>