pub struct ExecutorEntry {
pub name: &'static str,
pub type_name: &'static str,
pub make: fn() -> Box<dyn ErasedExecutor>,
}Expand description
注册表条目:#[derive(ExcelExecutor)] 自动提交
通过 registered_executors / executor_entry 查询,
想要运行时按名拿一个可用的执行器用 executor_by_name。
Fields§
§name: &'static str注册名(#[excel(register = "...")])
type_name: &'static str模型类型名(调试 / 前端展示用)
make: fn() -> Box<dyn ErasedExecutor>工厂:创建一个擦除了具体类型的执行器(预览返回 JSON)
Trait Implementations§
impl Collect for ExecutorEntry
Auto Trait Implementations§
impl Freeze for ExecutorEntry
impl RefUnwindSafe for ExecutorEntry
impl Send for ExecutorEntry
impl Sync for ExecutorEntry
impl Unpin for ExecutorEntry
impl UnsafeUnpin for ExecutorEntry
impl UnwindSafe for ExecutorEntry
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more