NodeHandler

Trait NodeHandler 

Source
pub trait NodeHandler: Clone {
    type NodeData: NodeDataType;
    type TraceData: TraceDataType;

    // Required method
    fn handle(
        &self,
        ctx: NodeContext<Self::NodeData, Self::TraceData>,
    ) -> impl Future<Output = NodeResult>;

    // Provided methods
    fn transform_attributes(
        &self,
        ctx: &NodeContext<Self::NodeData, Self::TraceData>,
    ) -> Option<TransformAttributes> { ... }
    fn after_transform_attributes(
        &self,
        ctx: &NodeContext<Self::NodeData, Self::TraceData>,
    ) -> impl Future<Output = Result<(), NodeError>> { ... }
}

Required Associated Types§

Source

type NodeData: NodeDataType

Source

type TraceData: TraceDataType

Required Methods§

Source

fn handle( &self, ctx: NodeContext<Self::NodeData, Self::TraceData>, ) -> impl Future<Output = NodeResult>

Provided Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§