GamendWeb.RealtimeEvents (gamend_web v1.0.1216)

Copy Markdown View Source

Registry of every server→client channel event.

Event names are bare strings at their push/push_event call sites, so they cannot be enumerated at runtime — this list is the enumerable source of truth. A drift test (realtime_events_drift_test.exs) greps the channel sources and fails when a pushed literal is missing here or an entry here no longer exists in the code, which is what keeps the two in sync.

pb: true marks events with a protobuf mapping in GamendWeb.EventCodec (sent as binary frames on ?format=protobuf sockets; JSON otherwise).

Summary

Functions

Every server→client event as a list of maps.

The distinct event names in the registry.

Types

entry()

@type entry() :: %{
  topic: String.t(),
  event: String.t(),
  pb: boolean(),
  payload: String.t(),
  description: String.t()
}

Functions

all()

@spec all() :: [entry()]

Every server→client event as a list of maps.

names()

The distinct event names in the registry.