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

Hierarchy

Index

Properties

Optional isTTY

isTTY: true

readable

readable: boolean

writable

writable: boolean

Methods

addListener

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

    • event: string | symbol
    • listener: Function

    Returns this

emit

  • emit(event: string | symbol, ...args: any[]): boolean
  • Parameters

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

    Returns boolean

end

  • end(): void
  • end(buffer: Buffer, cb?: Function): void
  • end(str: string, cb?: Function): void
  • end(str: string, encoding?: string, cb?: Function): void
  • Returns void

  • Parameters

    • buffer: Buffer
    • Optional cb: Function

    Returns void

  • Parameters

    • str: string
    • Optional cb: Function

    Returns void

  • Parameters

    • str: string
    • Optional encoding: string
    • Optional cb: Function

    Returns void

eventNames

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

getMaxListeners

  • getMaxListeners(): number
  • Returns number

isPaused

  • isPaused(): boolean
  • Returns 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[]

on

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

    • event: string | symbol
    • listener: Function

    Returns this

once

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

    • event: string | symbol
    • listener: Function

    Returns this

pause

  • pause(): this
  • Returns this

pipe

  • pipe<T>(destination: T, options?: object): T
  • Type parameters

    Parameters

    • destination: T
    • Optional options: object
      • Optional end?: boolean

    Returns T

prependListener

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

    • event: string | symbol
    • listener: Function

    Returns this

prependOnceListener

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

    • event: string | symbol
    • listener: Function

    Returns this

read

  • read(size?: number): string | Buffer
  • Parameters

    • Optional size: number

    Returns string | Buffer

removeAllListeners

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

    • Optional event: string | symbol

    Returns this

removeListener

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

    • event: string | symbol
    • listener: Function

    Returns this

resume

  • resume(): this
  • Returns this

setEncoding

  • setEncoding(encoding: string | null): void
  • Parameters

    • encoding: string | null

    Returns void

setMaxListeners

  • setMaxListeners(n: number): this
  • Parameters

    • n: number

    Returns this

unpipe

  • unpipe<T>(destination?: T): void
  • Type parameters

    Parameters

    • Optional destination: T

    Returns void

unshift

  • unshift(chunk: string): void
  • unshift(chunk: Buffer): void
  • Parameters

    • chunk: string

    Returns void

  • Parameters

    Returns void

wrap

write

  • write(buffer: Buffer | string, cb?: Function): boolean
  • write(str: string, encoding?: string, cb?: Function): boolean
  • Parameters

    • buffer: Buffer | string
    • Optional cb: Function

    Returns boolean

  • Parameters

    • str: string
    • Optional encoding: string
    • Optional cb: Function

    Returns boolean

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