Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface MessageQueue<Message>

Handles delivery of a sequence of sent Messages - which can be any javascript value - for one or more receivers to process when they are ready.

Type parameters

  • Message

Hierarchy

  • MessageQueue

Index

Properties

Properties

receive

receive: () => Promise<Message>

Type declaration

    • (): Promise<Message>
    • Takes a message from the message backlog or waits for the next send() call if there is no backlog.

      Returns Promise<Message>

send

send: (message: Message) => boolean

Type declaration

    • (message: Message): boolean
    • Delivers message to any waiting receive() call or adds to a backlog for a future caller to receive.

      Parameters

      • message: Message

      Returns boolean

Generated using TypeDoc