Skip to main content

Crate dlep_ext

Crate dlep_ext 

Source
Expand description

DLEP extension plug-in API.

Extensions declare the ExtensionIds they advertise in Session Initialization, and provide hooks to handle unknown data items and messages, or to observe session/destination state transitions.

The trait lives in its own crate (depending only on dlep-core) so third-party extensions do not pull the daemon runtime.

Structs§

DestinationStateSnapshot
ExtensionRegistry
Registry of configured extensions. Cheap to clone (holds Arcs).
SessionId
Opaque session identifier produced by the runtime. Copy-cheap for passing into hooks. The runtime mints these per-daemon (not process-wide), so two daemons sharing one process have independent id-spaces.
SessionStateSnapshot
Session lifecycle state exposed to negotiated extensions.

Enums§

ExtHandled
Role
Which side of the DLEP protocol a session is on. Set explicitly by the daemon when spawning a session task so extensions can reason about directionality without deriving it from the initial FSM event.

Traits§

DlepExtension
Extension plug-in trait. All hooks have default empty implementations so a real extension only overrides what it cares about.
ExtensionCtx
Context handed to every hook. Extensions may queue outbound messages and emit opaque application-level events, but cannot mutate FSM state.