Skip to main content

MessageCracker

Trait MessageCracker 

Source
pub trait MessageCracker {
    // Required method
    fn crack(&mut self, message: &Message) -> bool;
}
Expand description

A version-agnostic marker for a type that dispatches inbound messages to typed handlers.

Implementors typically delegate to one or more generated crack_<version> functions from truefix-dict (see the module docs above).

Required Methods§

Source

fn crack(&mut self, message: &Message) -> bool

Attempt to dispatch message to a typed handler. Returns whether a handler matched.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§