CommBus.Protocol.Validator (CommBus v0.1.0)

Copy Markdown View Source

Validates assembled protocol packets before they are forwarded to downstream routers.

Summary

Functions

Ensures a packet has well-formed messages, sections, and metadata.

Same as validate/1 but raises on failure.

Functions

validate(packet)

@spec validate(CommBus.Protocol.Packet.t()) :: :ok | {:error, term()}

Ensures a packet has well-formed messages, sections, and metadata.

validate!(packet)

Same as validate/1 but raises on failure.