Worker | typescript
Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Properties

exitedAfterDisconnect

exitedAfterDisconnect: boolean

id

id: string

process

process: ChildProcess

suicide

suicide: boolean

Static defaultMaxListeners

defaultMaxListeners: number

Methods

addListener

  • addListener(event: string, listener: Function): this
  • addListener(event: "disconnect", listener: function): this
  • addListener(event: "error", listener: function): this
  • addListener(event: "exit", listener: function): this
  • addListener(event: "listening", listener: function): this
  • addListener(event: "message", listener: function): this
  • addListener(event: "online", listener: function): this
  • events.EventEmitter

    1. disconnect
    2. error
    3. exit
    4. listening
    5. message
    6. online

    Parameters

    • event: string
    • listener: Function

    Returns this

  • Parameters

    • event: "disconnect"
    • listener: function
        • (): void
        • Returns void

    Returns this

  • Parameters

    • event: "error"
    • listener: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns this

  • Parameters

    • event: "exit"
    • listener: function
        • (code: number, signal: string): void
        • Parameters

          • code: number
          • signal: string

          Returns void

    Returns this

  • Parameters

    • event: "listening"
    • listener: function

    Returns this

  • Parameters

    • event: "message"
    • listener: function

    Returns this

  • Parameters

    • event: "online"
    • listener: function
        • (): void
        • Returns void

    Returns this

destroy

  • destroy(signal?: string): void
  • Parameters

    • Optional signal: string

    Returns void

disconnect

  • disconnect(): void
  • Returns void

emit

  • emit(event: string | symbol, ...args: any[]): boolean
  • emit(event: "disconnect", listener: function): boolean
  • emit(event: "error", listener: function): boolean
  • emit(event: "exit", listener: function): boolean
  • emit(event: "listening", listener: function): boolean
  • emit(event: "message", listener: function): boolean
  • emit(event: "online", listener: function): boolean
  • Parameters

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

    Returns boolean

  • Parameters

    • event: "disconnect"
    • listener: function
        • (): void
        • Returns void

    Returns boolean

  • Parameters

    • event: "error"
    • listener: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns boolean

  • Parameters

    • event: "exit"
    • listener: function
        • (code: number, signal: string): void
        • Parameters

          • code: number
          • signal: string

          Returns void

    Returns boolean

  • Parameters

    • event: "listening"
    • listener: function

    Returns boolean

  • Parameters

    • event: "message"
    • listener: function

    Returns boolean

  • Parameters

    • event: "online"
    • listener: function
        • (): void
        • Returns void

    Returns boolean

eventNames

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

getMaxListeners

  • getMaxListeners(): number

isConnected

  • isConnected(): boolean
  • Returns boolean

isDead

  • isDead(): boolean
  • Returns boolean

kill

  • kill(signal?: string): void
  • Parameters

    • Optional signal: string

    Returns void

listenerCount

  • listenerCount(type: string | symbol): number

listeners

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

    • event: string | symbol

    Returns Function[]

on

  • on(event: string, listener: Function): this
  • on(event: "disconnect", listener: function): this
  • on(event: "error", listener: function): this
  • on(event: "exit", listener: function): this
  • on(event: "listening", listener: function): this
  • on(event: "message", listener: function): this
  • on(event: "online", listener: function): this
  • Parameters

    • event: string
    • listener: Function

    Returns this

  • Parameters

    • event: "disconnect"
    • listener: function
        • (): void
        • Returns void

    Returns this

  • Parameters

    • event: "error"
    • listener: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns this

  • Parameters

    • event: "exit"
    • listener: function
        • (code: number, signal: string): void
        • Parameters

          • code: number
          • signal: string

          Returns void

    Returns this

  • Parameters

    • event: "listening"
    • listener: function

    Returns this

  • Parameters

    • event: "message"
    • listener: function

    Returns this

  • Parameters

    • event: "online"
    • listener: function
        • (): void
        • Returns void

    Returns this

once

  • once(event: string, listener: Function): this
  • once(event: "disconnect", listener: function): this
  • once(event: "error", listener: function): this
  • once(event: "exit", listener: function): this
  • once(event: "listening", listener: function): this
  • once(event: "message", listener: function): this
  • once(event: "online", listener: function): this
  • Parameters

    • event: string
    • listener: Function

    Returns this

  • Parameters

    • event: "disconnect"
    • listener: function
        • (): void
        • Returns void

    Returns this

  • Parameters

    • event: "error"
    • listener: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns this

  • Parameters

    • event: "exit"
    • listener: function
        • (code: number, signal: string): void
        • Parameters

          • code: number
          • signal: string

          Returns void

    Returns this

  • Parameters

    • event: "listening"
    • listener: function

    Returns this

  • Parameters

    • event: "message"
    • listener: function

    Returns this

  • Parameters

    • event: "online"
    • listener: function
        • (): void
        • Returns void

    Returns this

prependListener

  • prependListener(event: string, listener: Function): this
  • prependListener(event: "disconnect", listener: function): this
  • prependListener(event: "error", listener: function): this
  • prependListener(event: "exit", listener: function): this
  • prependListener(event: "listening", listener: function): this
  • prependListener(event: "message", listener: function): this
  • prependListener(event: "online", listener: function): this
  • Parameters

    • event: string
    • listener: Function

    Returns this

  • Parameters

    • event: "disconnect"
    • listener: function
        • (): void
        • Returns void

    Returns this

  • Parameters

    • event: "error"
    • listener: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns this

  • Parameters

    • event: "exit"
    • listener: function
        • (code: number, signal: string): void
        • Parameters

          • code: number
          • signal: string

          Returns void

    Returns this

  • Parameters

    • event: "listening"
    • listener: function

    Returns this

  • Parameters

    • event: "message"
    • listener: function

    Returns this

  • Parameters

    • event: "online"
    • listener: function
        • (): void
        • Returns void

    Returns this

prependOnceListener

  • prependOnceListener(event: string, listener: Function): this
  • prependOnceListener(event: "disconnect", listener: function): this
  • prependOnceListener(event: "error", listener: function): this
  • prependOnceListener(event: "exit", listener: function): this
  • prependOnceListener(event: "listening", listener: function): this
  • prependOnceListener(event: "message", listener: function): this
  • prependOnceListener(event: "online", listener: function): this
  • Parameters

    • event: string
    • listener: Function

    Returns this

  • Parameters

    • event: "disconnect"
    • listener: function
        • (): void
        • Returns void

    Returns this

  • Parameters

    • event: "error"
    • listener: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns this

  • Parameters

    • event: "exit"
    • listener: function
        • (code: number, signal: string): void
        • Parameters

          • code: number
          • signal: string

          Returns void

    Returns this

  • Parameters

    • event: "listening"
    • listener: function

    Returns this

  • Parameters

    • event: "message"
    • listener: function

    Returns this

  • Parameters

    • event: "online"
    • listener: function
        • (): void
        • Returns void

    Returns this

removeAllListeners

  • removeAllListeners(event?: string | symbol): this

removeListener

  • removeListener(event: string | symbol, listener: Function): this

send

  • send(message: any, sendHandle?: any, callback?: function): boolean
  • Parameters

    • message: any
    • Optional sendHandle: any
    • Optional callback: function
        • (error: Error): void
        • Parameters

          • error: Error

          Returns void

    Returns boolean

setMaxListeners

  • setMaxListeners(n: number): this

Static listenerCount

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

    Returns number

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc