[][src]Trait lambda_runtime_core::Handler

pub trait Handler<EventError> {
    fn run(
        &mut self,
        event: Vec<u8>,
        ctx: Context
    ) -> Result<Vec<u8>, EventError>; }

Functions acting as a handler must conform to this type.

Required methods

fn run(&mut self, event: Vec<u8>, ctx: Context) -> Result<Vec<u8>, EventError>

Run the handler.

Loading content...

Implementors

impl<'ev, Function, EventError> Handler<EventError> for Function where
    Function: FnMut(Vec<u8>, Context) -> Result<Vec<u8>, EventError>,
    EventError: Fail + LambdaErrorExt + Display + Send + Sync
[src]

Loading content...