Trait rustmex::message::MexMessage
source · [−]Expand description
Trait describing a “mex message”, i.e. the input to mex’s warning and error functions.
The methods return &str, because this trait is meant to be used within Rust library code. Having this trait return C string pointers is too much of a burden on the users; conversions to c strings for matlab are done by rustmex
Required Methods
Trait Implementations
sourceimpl AsRef<dyn MexMessage + 'static> for Error
impl AsRef<dyn MexMessage + 'static> for Error
sourcefn as_ref<'a>(&'a self) -> &'a (dyn MexMessage + 'static)
fn as_ref<'a>(&'a self) -> &'a (dyn MexMessage + 'static)
Converts this type into a shared reference of the (usually inferred) input type.
Implementors
impl MexMessage for FromMatlabError
impl MexMessage for ToMatlabError
impl MexMessage for MissingVariable
impl<Id, Msg> MexMessage for AdHoc<Id, Msg> where
Id: AsRef<str>,
Msg: Display,
Convenience implementation for MexMessage for two str’s. Sometimes an ad-hoc error/warning is generated, from two strings instead of a specific error type.