pub trait MessageArguments: Sized {
// Required method
unsafe fn invoke<R>(
imp: unsafe extern "C" fn(),
obj: *mut Object,
sel: Sel,
args: Self,
) -> R
where R: Any;
}
Expand description
Types that may be used as the arguments of an Objective-C message.
Required Methods§
Sourceunsafe fn invoke<R>(
imp: unsafe extern "C" fn(),
obj: *mut Object,
sel: Sel,
args: Self,
) -> Rwhere
R: Any,
unsafe fn invoke<R>(
imp: unsafe extern "C" fn(),
obj: *mut Object,
sel: Sel,
args: Self,
) -> Rwhere
R: Any,
Invoke an Imp
with the given object, selector, and arguments.
This method is the primitive used when sending messages and should not
be called directly; instead, use the msg_send!
macro or, in cases
with a dynamic selector, the Message::send_message
method.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.