Macro plugin_interface

Source
plugin_interface!() { /* proc-macro */ }
Expand description

Define an interface for a plugin. See the dynamic_plugin crate documentation for more.

§Example

plugin_interface! {
    extern trait ExamplePlugin {
        /// Ask the plugin to do a thing
        fn do_a_thing();
        /// Say hello to a person
        fn say_hello(to: *const c_char) -> bool;
    }
}