hsmtool::commands

Trait Dispatch

Source
pub trait Dispatch: Serialize + Deserialize {
    // Required method
    fn run(
        &self,
        context: &dyn Any,
        hsm: &Module,
        session: Option<&Session>,
    ) -> Result<Box<dyn Annotate>>;

    // Provided method
    fn leaf(&self) -> &dyn Dispatch
       where Self: Sized { ... }
}

Required Methods§

Source

fn run( &self, context: &dyn Any, hsm: &Module, session: Option<&Session>, ) -> Result<Box<dyn Annotate>>

Provided Methods§

Source

fn leaf(&self) -> &dyn Dispatch
where Self: Sized,

Trait Implementations§

Source§

impl<'typetag> Serialize for dyn Dispatch + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'typetag> Serialize for dyn Dispatch + Send + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'typetag> Serialize for dyn Dispatch + Send + Sync + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<'typetag> Serialize for dyn Dispatch + Sync + 'typetag

Source§

fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where S: Serializer,

Serialize this value into the given Serde serializer. Read more

Implementors§