pub trait FunctionMiddleware {
type Error: Debug;
// Required method
fn feed_event<'a, 'b: 'a>(
&mut self,
op: Event<'a, 'b>,
module_info: &ModuleInfo,
sink: &mut EventSink<'a, 'b>,
source_loc: u32,
) -> Result<(), Self::Error>;
}
Expand description
A trait that represents the signature required to implement middleware for a function.
Required Associated Types§
Required Methods§
Sourcefn feed_event<'a, 'b: 'a>(
&mut self,
op: Event<'a, 'b>,
module_info: &ModuleInfo,
sink: &mut EventSink<'a, 'b>,
source_loc: u32,
) -> Result<(), Self::Error>
fn feed_event<'a, 'b: 'a>( &mut self, op: Event<'a, 'b>, module_info: &ModuleInfo, sink: &mut EventSink<'a, 'b>, source_loc: u32, ) -> Result<(), Self::Error>
Processes the given event, module info and sink.