Struct Plugin

Source
#[repr(C)]
pub struct Plugin {
Show 14 fields pub plugin_type: PluginType, pub info: *const c_void, pub name: *const u8, pub author: *const u8, pub descr: *const u8, pub license: License, pub init: *const InitFunc, pub check_uninstall: *const CheckUninstallFunc, pub deinit: *const DeinitFunc, pub version: u32, pub status_vars: *const c_void, pub system_vars: *const c_void, pub reserved: *const c_void, pub flags: c_ulong,
}
Expand description

A plugin description.

Fields§

§plugin_type: PluginType

The type of the plugin.

§info: *const c_void

Pointer to one of the supported info structures.

These are:

  • StorageEngineInfo
§name: *const u8

The name of the plugin.

§author: *const u8

The author (Person or organization).

§descr: *const u8

The description.

§license: License

The license under which the plugin is published.

§init: *const InitFunc

Function to invoke when plugin is loaded.

§check_uninstall: *const CheckUninstallFunc

Function to invoke when plugin is uninstalled.

§deinit: *const DeinitFunc

Function to invoke when plugin is unloaded.

§version: u32

Version number of the plugin.

§status_vars: *const c_void

TODO: SHOW STATUS Server status variable

§system_vars: *const c_void

TODO: Definition of system vars structure for access their information in the plugin

§reserved: *const c_void

Reserved for dependency checking.

§flags: c_ulong

Flags for the plugin.

Implementations§

Source§

impl Plugin

Source

pub const fn zero() -> Self

Create a Plugin information structure with all fields being zero.

Trait Implementations§

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.