Options
All
  • Public
  • Public/Protected
  • All
Menu

Class WriteableMessage

A writable message that can be serialised into a BufferOutputStream

Hierarchy

Index

Constructors

constructor

Properties

data

data: Buffer

The message's data

encoding

encoding: encoding

The message encoding

headers

headers: string[]

Additional message headers

Optional id

id: undefined | number

The message ID

Private stream

The output stream

Optional topic

topic: undefined | string

A topic associated with the message

type

type: types

The message type

Methods

getBuffer

  • getBuffer(): Buffer
  • Get the buffer

    Returns Buffer

    the buffer that the output has been written into

getInputStream

  • getInputStream(): any
  • Create an input stream from the message's data

    Returns any

    an input stream that can be deserialised

getStream

  • Get the output stream

    Returns BufferOutputStream

    the output stream that writes into the message's data buffer