Options
All
  • Public
  • Public/Protected
  • All
Menu

Class MessageBuilder<B, H, M>

The builder helps to create messages: commands, queries, results and events.

Type parameters

Hierarchy

  • MessageBuilder

Index

Constructors

Private constructor

  • new MessageBuilder<B, H, M>(_messageKind: MessageKind, _messageType?: string, _messageId?: string, _body?: B, _headers?: Partial<H>): MessageBuilder<B, H, M>

Properties

Protected Optional _body

_body?: B

Protected _headers

_headers: Partial<H> = {}

Protected _messageId

_messageId: string = ...

Protected Readonly _messageKind

_messageKind: MessageKind

Protected _messageType

_messageType: string = _messageKind

Methods

body

build

  • build(): M

headers

identifier

type

Static command

Static empty

Static event

Static get

Static query

Static result

Generated using TypeDoc