[][src]Trait kernel::hil::digest::Client

pub trait Client<'a, T: DigestType> {
    fn add_data_done(
        &'a self,
        result: Result<(), ReturnCode>,
        data: &'static mut [u8]
    );
fn hash_done(
        &'a self,
        result: Result<(), ReturnCode>,
        digest: &'static mut T
    ); }

Implement this trait and use set_client() in order to receive callbacks.

Required methods

fn add_data_done(
    &'a self,
    result: Result<(), ReturnCode>,
    data: &'static mut [u8]
)

This callback is called when the data has been added to the digest engine. On error or success data will contain a reference to the original data supplied to add_data().

fn hash_done(&'a self, result: Result<(), ReturnCode>, digest: &'static mut T)

This callback is called when a digest is computed. On error or success digest will contain a reference to the original data supplied to run().

Loading content...

Implementors

Loading content...