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: Proc) -> Self
pub const fn new(name: &'static str, proc: Proc) -> Self
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
pub const fn with_public(self, public: bool) -> Self
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) -> Proc
pub const fn proc(&self) -> Proc
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.
sourcepub const fn is_public(&self) -> bool
pub const fn is_public(&self) -> bool
Returns true
if the proc has pub
visibility specifier, but can be
overriden with the public
attribute.
Can be used when choosing which stored procedures the “public” role should have access to.
See https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_space/_user/ for more info about role “public”.