pub struct Plugin<T> where
    T: Clone
{ pub option: HashSet<RpcOption>, pub rpc_method: HashMap<String, Box<dyn RPCCommand<T>>>, pub rpc_info: HashSet<RPCMethodInfo>, pub rpc_hook: HashMap<String, Box<dyn RPCCommand<T>>>, pub hook_info: HashSet<RPCHookInfo>, pub rpc_notification: HashMap<String, Box<dyn RPCCommand<T>>>, pub dynamic: bool, /* private fields */ }

Fields

option: HashSet<RpcOption>

all the option contained inside the hash map.

rpc_method: HashMap<String, Box<dyn RPCCommand<T>>>

all the options rpc method that the plugin need to support, included the builtin rpc method.

rpc_info: HashSet<RPCMethodInfo>

keep the info of the method in a separate list FIXME: move the RPCMethodInfo as key of the rpc_method map.

rpc_hook: HashMap<String, Box<dyn RPCCommand<T>>>

all the hook where the plugin is register during the configuration

hook_info: HashSet<RPCHookInfo>

keep all the info about the hooks in a separate set. FIXME: put the RPCHookInfo as key of the hash map.

rpc_notification: HashMap<String, Box<dyn RPCCommand<T>>>

all the notification that the plugin is register on

dynamic: bool

mark a plugin as dynamic, in this way the plugin can be run from core lightning without stop the lightningd daemon

Implementations

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.