Struct tarantool_test::test_entrypoint::Proc
source · pub struct Proc { /* private fields */ }
Expand description
Description of a tarantool stored procedure defined using the
#[
tarantool::proc
]
macro attribute.
See also all_procs
.
Implementations§
source§impl Proc
impl Proc
sourcepub const fn new(
name: &'static str,
proc: unsafe extern "C" fn(_: FunctionCtx, _: FunctionArgs) -> i32
) -> Proc
pub const fn new( name: &'static str, proc: unsafe extern "C" fn(_: FunctionCtx, _: FunctionArgs) -> i32 ) -> Proc
Create a new stored proc description.
This function is called when #[
tarantool::proc
]
attribute is
used, so users don’t usually use it directly.
See also module_path
sourcepub const fn name(&self) -> &'static str
pub const fn name(&self) -> &'static str
Get the name of the stored procedure NOT including the module name.
sourcepub const fn proc(
&self
) -> unsafe extern "C" fn(_: FunctionCtx, _: FunctionArgs) -> i32
pub const fn proc( &self ) -> unsafe extern "C" fn(_: FunctionCtx, _: FunctionArgs) -> i32
Get the proc’s function pointer.
This function is usually not necessary for defining tarantool’s stored procedures, the name is enough. But it is there if you need it for some reason.
Trait Implementations§
source§impl PartialEq<Proc> for Proc
impl PartialEq<Proc> for Proc
impl Eq for Proc
impl StructuralEq for Proc
impl StructuralPartialEq for Proc
Auto Trait Implementations§
impl RefUnwindSafe for Proc
impl Send for Proc
impl Sync for Proc
impl Unpin for Proc
impl UnwindSafe for Proc
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