Options
All
  • Public
  • Public/Protected
  • All
Menu

Class RxJsonSocket

Special variant of an RxSocketSubject that translates between regular JS objects and ArrayBuffer streams. Best used for sending high-level protocol values over a low-level stream.

Hierarchy

  • RxJsonSocket

Index

Constructors

constructor

Properties

Readonly bufferStream

bufferStream: RxSocket<Uint8Array> = ...

Protected Readonly bufferStreamSubject

bufferStreamSubject: RxSocketSubject<Uint8Array> = ...

Readonly jsonStream

jsonStream: RxSocket<any> = ...

Protected Readonly jsonStreamSubject

jsonStreamSubject: RxSocketSubject<any> = ...

options

options: JsonBufferMapOptions = ...

Readonly textStream

textStream: RxSocket<string> = ...

Protected Readonly textStreamSubject

textStreamSubject: RxSocketSubject<string> = ...

Methods

bufferToJson

  • bufferToJson(value: Uint8Array): any

emit

  • emit(jsonMessage: any): void

jsonToBuffer

  • jsonToBuffer(value: any): Uint8Array

Protected linkStreams

  • linkStreams(): void

send

  • send(jsonMessage: any): Observable<any>

setBufferReceiveSource

  • setBufferReceiveSource(source: Subscribable<Uint8Array>): void

Generated using TypeDoc