Skip to main content

TypedEvent

Trait TypedEvent 

Source
pub trait TypedEvent {
    type Payload: Serialize + DeserializeOwned + Clone + Send + Sync + 'static;

    const NAME: &'static str;
    const MODE: Dispatch;
    const AROUND: bool;
}
Expand description

Compile-time binding between a catalog event and its payload type.

NAME/MODE/AROUND must mirror the event’s crate::events_catalog::EventContract; the typed_events_match_catalog_contracts test fails on drift.

Required Associated Constants§

Source

const NAME: &'static str

Canonical event name (an events_catalog::ev::* constant).

Source

const MODE: Dispatch

Declared dispatch mode.

Source

const AROUND: bool

True for around-middleware waterfalls (on_waterfall registry).

Required Associated Types§

Source

type Payload: Serialize + DeserializeOwned + Clone + Send + Sync + 'static

Wire shape of the event payload.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl TypedEvent for AgentAdmitEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::AGENT_ADMIT

Source§

const MODE: Dispatch = Dispatch::Bail

Source§

const AROUND: bool = false

Source§

type Payload = AgentAdmitPayload

Source§

impl TypedEvent for AgentCompletedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::AGENT_COMPLETED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = AgentCompletedPayload

Source§

impl TypedEvent for AgentFailedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::AGENT_FAILED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = AgentFailedPayload

Source§

impl TypedEvent for AgentRunEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::AGENT_RUN

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = AgentRunRequest

Source§

impl TypedEvent for AgentStartedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::AGENT_STARTED

Source§

const MODE: Dispatch = Dispatch::Parallel

Source§

const AROUND: bool = false

Source§

type Payload = AgentStartedPayload

Source§

impl TypedEvent for AgentUsageEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::AGENT_USAGE

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = AgentUsagePayload

Source§

impl TypedEvent for LlmCompleteEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::LLM_COMPLETE

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = LlmCompleteRequest

Source§

impl TypedEvent for LlmGenerateEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::LLM_GENERATE

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = LlmGeneratePayload

Source§

impl TypedEvent for LlmGenerateToolsEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::LLM_GENERATE_TOOLS

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = LlmGenerateToolsPayload

Source§

impl TypedEvent for LlmGetClientEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::LLM_GET_CLIENT

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = LlmGetClientPayload

Source§

impl TypedEvent for PipelineFanoutCompletedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::PIPELINE_FANOUT_COMPLETED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = PipelineFanoutCompletedPayload

Source§

impl TypedEvent for PipelineStepFinishedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::PIPELINE_STEP_FINISHED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = PipelineStepFinishedPayload

Source§

impl TypedEvent for PipelineStepStartedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::PIPELINE_STEP_STARTED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = PipelineStepStartedPayload

Source§

impl TypedEvent for ScheduleDispatchedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::SCHEDULER_SCHEDULE_DISPATCHED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = ScheduleDispatchedPayload

Source§

impl TypedEvent for SchedulerAdmitEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::SCHEDULER_ADMIT

Source§

const MODE: Dispatch = Dispatch::Bail

Source§

const AROUND: bool = false

Source§

type Payload = SchedulerAdmitPayload

Source§

impl TypedEvent for SchedulerBeforeRunEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::SCHEDULER_BEFORE_RUN

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = SchedulerBeforeRunPayload

Source§

impl TypedEvent for SchedulerTickEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::SCHEDULER_TICK

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = SchedulerTickPayload

Source§

impl TypedEvent for ServiceChangedEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::SERVICE_CHANGED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = ServiceChangedPayload

Source§

impl TypedEvent for ToolsExecuteEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::TOOLS_EXECUTE

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = ToolsExecutePayload

Source§

impl TypedEvent for ToolsListEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::TOOLS_LIST

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = ToolsListRequest

Source§

impl TypedEvent for ToolsResolveEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::TOOLS_RESOLVE

Source§

const MODE: Dispatch = Dispatch::Waterfall

Source§

const AROUND: bool = true

Source§

type Payload = ToolsResolveRequest

Source§

impl TypedEvent for TriggerFiredEvent

Source§

const NAME: &'static str = crate::events_catalog::ev::TRIGGER_FIRED

Source§

const MODE: Dispatch = Dispatch::Emit

Source§

const AROUND: bool = false

Source§

type Payload = TriggerFiredPayload