The wire description of an action invocation.
More...
#include <cpp/a11/data/types.h>
|
| size_t | ApproxBytes () const |
| | Estimate memory/wire weight for session and transport limits.
|
| |
| std::string | DebugString () const |
| | Return a concise representation suitable for logs and diagnostics.
|
| |
| absl::Status | Validate () const |
| | Validate the invocation id, action name, ports, and headers.
|
| |
| absl::StatusOr< Bytes > | ToMsgpack () const |
| | Encodes this message as MessagePack bytes.
|
| |
| absl::Status | ToMsgpackInto (MsgpackWriter *absl_nonnull writer) const |
| | Append this record's fields to an already-open writer.
|
| |
|
| std::string | id |
| | Unique id of this action instance.
|
| |
| std::string | name |
| | Registered action name.
|
| |
| std::vector< Port > | inputs {} |
| | Input port -> node bindings.
|
| |
| std::vector< Port > | outputs {} |
| | Output port -> node bindings.
|
| |
| ByteMap | headers {} |
| | Per-call headers.
|
| |
The wire description of an action invocation.
Names the action (name) and the specific instance (id), lists the a11::data::Port bindings for its inputs and outputs, and carries per-call headers. This is what a peer sends to dispatch an action and what an a11::actions::Action produces to describe itself.
◆ ApproxBytes()
| size_t a11::data::ActionMessage::ApproxBytes |
( |
| ) |
const |
Estimate memory/wire weight for session and transport limits.
◆ DebugString()
| std::string a11::data::ActionMessage::DebugString |
( |
| ) |
const |
Return a concise representation suitable for logs and diagnostics.
◆ FromMsgpack()
| absl::StatusOr< ActionMessage > a11::data::ActionMessage::FromMsgpack |
( |
std::string_view |
bytes | ) |
|
|
static |
◆ ToMsgpack()
| absl::StatusOr< Bytes > a11::data::ActionMessage::ToMsgpack |
( |
| ) |
const |
Encodes this message as MessagePack bytes.
◆ ToMsgpackInto()
| absl::Status a11::data::ActionMessage::ToMsgpackInto |
( |
MsgpackWriter *absl_nonnull |
writer | ) |
const |
Append this record's fields to an already-open writer.
What ToMsgpack() is built from, and what a parent record calls through MsgpackWriter::PackRecord so that nesting costs no buffer of its own. Both produce the same bytes; this one avoids the intermediate string.
Assumes the record is already valid. Validate() recurses through nested records, so validating here as well would re-check every nested id once per ancestor level. ToMsgpack() validates the whole tree once and then calls this; a caller reaching for this directly should do the same, and any caller that got its record from FromMsgpack() already has.
◆ Validate()
| absl::Status a11::data::ActionMessage::Validate |
( |
| ) |
const |
Validate the invocation id, action name, ports, and headers.
◆ AbslStringify
◆ operator==
◆ headers
| ByteMap a11::data::ActionMessage::headers {} |
◆ id
| std::string a11::data::ActionMessage::id |
Unique id of this action instance.
◆ inputs
| std::vector<Port> a11::data::ActionMessage::inputs {} |
Input port -> node bindings.
◆ name
| std::string a11::data::ActionMessage::name |
◆ outputs
| std::vector<Port> a11::data::ActionMessage::outputs {} |
Output port -> node bindings.
The documentation for this struct was generated from the following files: