The module itself has to be populate the Command instance

This will be done by the module returning a lambda to build the
command instance.
This commit is contained in:
Matthias Beyer 2015-11-10 19:28:19 +01:00
parent f4dbec72ee
commit ba91e7ee26

View file

@ -51,5 +51,9 @@ pub trait Module {
fn execute(&self, rt : &Runtime) -> ModuleResult; fn execute(&self, rt : &Runtime) -> ModuleResult;
fn shutdown(&self, rt : &Runtime) -> ModuleResult; fn shutdown(&self, rt : &Runtime) -> ModuleResult;
fn getCommandBuilder<T>() -> F
where F: FnOnce(StorageBackend) -> T,
T: ExecutableCommand;
} }