Class Readable

Hierarchy

Index

Constructor methods

Properties

Methods

Constructor methods

constructor(opts?: ReadableOptions): Readable

Parameters

Returns

Readable

Properties

public readable: boolean

Methods

public _read(size: number)

Parameters

  • size: number

public addListener(event: string, listener: Function): EventEmitter

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

public emit(event: string, args?: Array<any>): boolean

Parameters

  • event: string
  • args?: Array<any> optional

Returns

boolean

public listeners(event: string): Array<Function>

Parameters

  • event: string

Returns

Array<Function>

public on(event: string, listener: Function): EventEmitter

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

public once(event: string, listener: Function): EventEmitter

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

public pause()

public pipe(destination: T, options?: { end?: boolean; }): T

Parameters

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

Returns

T

public push(chunk: any, encoding?: string): boolean

Parameters

  • chunk: any
  • encoding?: string optional

Returns

boolean

public read(size?: number): any

Parameters

  • size?: number optional

Returns

any

public removeAllListeners(event?: string): EventEmitter

Parameters

  • event?: string optional

Returns

EventEmitter

public removeListener(event: string, listener: Function): EventEmitter

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

public resume()

public setEncoding(encoding: string)

Parameters

  • encoding: string

public setMaxListeners(n: number)

Parameters

  • n: number

public unpipe(destination?: T)

Parameters

  • destination?: T optional

public unshift(chunk: string)

Parameters

  • chunk: string

public unshift(chunk: Buffer)

Parameters

public wrap(oldStream: ReadableStream): ReadableStream

Parameters

Returns

ReadableStream