#[repr(C)]pub struct RuntimePluginApiV1 {
pub abi_version: u32,
pub plugin_name: unsafe extern "C" fn() -> RuntimeBytesRef,
pub schema_bytes: unsafe extern "C" fn() -> RuntimeBytesRef,
pub create_runtime: unsafe extern "C" fn(config: RuntimeBytesRef, out_runtime: *mut *mut c_void, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatus,
pub destroy_runtime: unsafe extern "C" fn(runtime: *mut c_void),
pub run_tx: unsafe extern "C" fn(runtime: *mut c_void, host: RuntimeHostContextV1, command: RuntimeCommandView, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatus,
pub validate_biz_invariants: unsafe extern "C" fn(runtime: *mut c_void, host: RuntimeReadContextV1, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatus,
pub on_unload: unsafe extern "C" fn(runtime: *mut c_void, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatus,
}Expand description
ABI function table returned by a runtime plugin entrypoint.
Fields§
§abi_version: u32ABI version implemented by the plugin.
plugin_name: unsafe extern "C" fn() -> RuntimeBytesRefReturns the plugin name.
schema_bytes: unsafe extern "C" fn() -> RuntimeBytesRefReturns schema IDL JSON bytes.
create_runtime: unsafe extern "C" fn(config: RuntimeBytesRef, out_runtime: *mut *mut c_void, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatusCreates a configured runtime plugin instance.
destroy_runtime: unsafe extern "C" fn(runtime: *mut c_void)Destroys a runtime plugin instance.
run_tx: unsafe extern "C" fn(runtime: *mut c_void, host: RuntimeHostContextV1, command: RuntimeCommandView, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatusRuns one command transaction.
validate_biz_invariants: unsafe extern "C" fn(runtime: *mut c_void, host: RuntimeReadContextV1, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatusValidates business invariants against read-only host state.
on_unload: unsafe extern "C" fn(runtime: *mut c_void, out_error: *mut RuntimeErrorBuf) -> RuntimeCallStatusUnloads a runtime plugin instance.
Auto Trait Implementations§
impl Freeze for RuntimePluginApiV1
impl RefUnwindSafe for RuntimePluginApiV1
impl Send for RuntimePluginApiV1
impl Sync for RuntimePluginApiV1
impl Unpin for RuntimePluginApiV1
impl UnsafeUnpin for RuntimePluginApiV1
impl UnwindSafe for RuntimePluginApiV1
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