#[repr(C)]pub struct som_method_def_t {
pub reserved: LPVOID,
pub name: som_atom_t,
pub params: usize,
pub func: Option<extern "C" fn(thing: *mut som_asset_t, argc: u32, argv: *const VALUE, p_result: &mut VALUE) -> BOOL>,
}
Expand description
Method of an asset.
Fields§
§reserved: LPVOID
§name: som_atom_t
Method name.
params: usize
Parameters count.
The actual arguments count can be lesser then specified here:
function asset.func(a,b,c); // native asset method accepts 3 parameters
asset.func("one"); // call with only one parameter.
func: Option<extern "C" fn(thing: *mut som_asset_t, argc: u32, argv: *const VALUE, p_result: &mut VALUE) -> BOOL>
Method body.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for som_method_def_t
impl RefUnwindSafe for som_method_def_t
impl !Send for som_method_def_t
impl !Sync for som_method_def_t
impl Unpin for som_method_def_t
impl UnwindSafe for som_method_def_t
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