Interface MessageEvent

All Superinterfaces:
BabelEvent
All Known Implementing Classes:
MessageInEvent, MessageOutFailedEvent, MessageOutSuccessEvent

public sealed interface MessageEvent extends BabelEvent permits MessageInEvent, MessageOutSuccessEvent, MessageOutFailedEvent
Sealed interface representing the outcome of a message send or receive operation on a BabelChannel.

The three permitted subtypes mirror the three possible results of sending a BabelMessage:

Protocols handle these events by annotating methods with @UponMessageIn, @UponMessageOutSuccess, or @UponMessageOutFailed respectively.

  • Method Summary

    Modifier and Type
    Method
    Description
    The message associated with this event.
  • Method Details

    • message

      BabelMessage message()
      The message associated with this event.
      Returns:
      the message