Skip to main content

plugin_entry

Macro plugin_entry 

Source
macro_rules! plugin_entry {
    ($factory:expr_2021) => { ... };
}
Expand description

Macro to generate the FFI entry point for a plugin

This macro creates the necessary extern "C" functions that the host will call to interact with the plugin.

§Example

use rustbridge_ffi::prelude::*;

struct MyPlugin;

// ... implement Plugin trait ...

rustbridge_ffi::plugin_entry!(MyPlugin::new);