Class ClientRequest

Hierarchy

Index

Constructor methods

Properties

Methods

Constructor methods

constructor(opts?: WritableOptions): Writable

Parameters

Returns

Writable

Properties

public writable: boolean

Methods

public _write(data: Buffer, encoding: string, callback: Function)

Parameters

  • data: Buffer
  • encoding: string
  • callback: Function

public _write(data: string, encoding: string, callback: Function)

Parameters

  • data: string
  • encoding: string
  • callback: Function

public abort()

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

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

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 emit(event: string, args?: Array<any>): boolean

Parameters

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

Returns

boolean

public end()

public end(buffer: Buffer, cb?: Function)

Parameters

  • buffer: Buffer
  • cb?: Function optional

public end(str: string, cb?: Function)

Parameters

  • str: string
  • cb?: Function optional

public end(str: string, encoding?: string, cb?: Function)

Parameters

  • str: string
  • encoding?: string optional
  • cb?: Function optional

public end(data?: any, encoding?: string)

Parameters

  • data?: any optional
  • encoding?: string optional

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

Parameters

  • event: string

Returns

Array<Function>

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 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 once(event: string, listener: Function): EventEmitter

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

public removeAllListeners(event?: string): EventEmitter

Parameters

  • event?: string optional

Returns

EventEmitter

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 removeListener(event: string, listener: Function): EventEmitter

Parameters

  • event: string
  • listener: Function

Returns

EventEmitter

public setMaxListeners(n: number)

Parameters

  • n: number

public setMaxListeners(n: number)

Parameters

  • n: number

public setNoDelay(noDelay?: boolean)

Parameters

  • noDelay?: boolean optional

public setSocketKeepAlive(enable?: boolean, initialDelay?: number)

Parameters

  • enable?: boolean optional
  • initialDelay?: number optional

public setTimeout(timeout: number, callback?: Function)

Parameters

  • timeout: number
  • callback?: Function optional

public write(buffer: Buffer): boolean

Parameters

Returns

boolean

public write(buffer: Buffer, cb?: Function): boolean

Parameters

  • buffer: Buffer
  • cb?: Function optional

Returns

boolean

public write(str: string, cb?: Function): boolean

Parameters

  • str: string
  • cb?: Function optional

Returns

boolean

public write(str: string, encoding?: string, cb?: Function): boolean

Parameters

  • str: string
  • encoding?: string optional
  • cb?: Function optional

Returns

boolean

public write(str: string, encoding?: string, fd?: string): boolean

Parameters

  • str: string
  • encoding?: string optional
  • fd?: string optional

Returns

boolean

public write(chunk: any, encoding?: string)

Parameters

  • chunk: any
  • encoding?: string optional