pub struct CommandRegistration {
pub rust_symbol: &'static str,
pub excel_name: &'static str,
pub description: Option<&'static str>,
pub shortcut: Option<&'static str>,
}Expand description
Registration metadata for an XLL command, which is deliberately distinct from a worksheet-function descriptor.
Fields§
§rust_symbol: &'static strUnmangled Rust-export command thunk name.
excel_name: &'static strExcel-visible command name.
description: Option<&'static str>Optional Excel-visible command description.
shortcut: Option<&'static str>Optional command shortcut text.
Implementations§
Source§impl CommandRegistration
impl CommandRegistration
Sourcepub const fn new(rust_symbol: &'static str, excel_name: &'static str) -> Self
pub const fn new(rust_symbol: &'static str, excel_name: &'static str) -> Self
Creates command metadata with no optional help or shortcut.
Sourcepub const fn description(self, description: &'static str) -> Self
pub const fn description(self, description: &'static str) -> Self
Adds Excel-visible command help text.
Sourcepub const fn type_text(&self) -> &'static str
pub const fn type_text(&self) -> &'static str
I is the documented 16-bit command return ABI; commands have no
Excel-visible arguments and use macro type 2 during registration.
Sourcepub fn validate(&self) -> Result<(), RegistrationError>
pub fn validate(&self) -> Result<(), RegistrationError>
Validates command metadata before lifecycle registration.
Trait Implementations§
Source§impl Clone for CommandRegistration
impl Clone for CommandRegistration
impl Copy for CommandRegistration
Auto Trait Implementations§
impl Freeze for CommandRegistration
impl RefUnwindSafe for CommandRegistration
impl Send for CommandRegistration
impl Sync for CommandRegistration
impl Unpin for CommandRegistration
impl UnsafeUnpin for CommandRegistration
impl UnwindSafe for CommandRegistration
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