use super::{ObjectVtable, OperationVTable, SettingVtable, ValueVTable}; use crate::{ callback::{OperationHandlerCallback, SettingGetterCallback, ValueGetterCallback}, handle::PluginInitializationState, }; use std::fmt::Debug; #[repr(C)] pub struct HostVTable {} #[repr(C)] #[derive(Clone, Copy)] pub struct InitializationVTable { pub register_object: unsafe extern "C" fn(*mut PluginInitializationState, &'static str, ObjectVtable), pub register_operation: unsafe extern "C" fn( *mut PluginInitializationState, &'static str, &'static str, OperationVTable, ), pub register_setting: unsafe extern "C" fn( *mut PluginInitializationState, &'static str, &'static str, SettingVtable, ), pub register_value: unsafe extern "C" fn( *mut PluginInitializationState, &'static str, &'static str, ValueVTable, ), pub operation_handler: unsafe extern "C" fn( *mut PluginInitializationState, &'static str, &'static str, OperationHandlerCallback, ), pub value_getter: unsafe extern "C" fn( *mut PluginInitializationState, &'static str, &'static str, ValueGetterCallback, ), pub setting_getter: unsafe extern "C" fn( *mut PluginInitializationState, &'static str, &'static str, SettingGetterCallback, ), } impl Debug for InitializationVTable { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { f.debug_struct("InitializationVTable").finish() } } unsafe impl Sync for InitializationVTable {} unsafe impl Send for InitializationVTable {}