PROJECT_FILE

Struct PROJECT_FILE 

Source
#[repr(C)]
pub struct PROJECT_FILE { pub get_param_string: unsafe extern "C" fn(key: LPCSTR) -> LPCSTR, pub set_param_string: unsafe extern "C" fn(key: LPCSTR, value: LPCSTR), pub get_param_binary: unsafe extern "C" fn(key: LPCSTR, data: *mut c_void, size: i32) -> bool, pub set_param_binary: unsafe extern "C" fn(key: LPCSTR, data: *mut c_void, size: i32), pub clear_params: unsafe extern "C" fn(), }
Expand description

プロジェクトファイル構造体 プロジェクトファイルのロード、セーブ時のコールバック関数内で利用出来ます プロジェクトの保存データはプラグイン毎のデータ領域になります

Fields§

§get_param_string: unsafe extern "C" fn(key: LPCSTR) -> LPCSTR

プロジェクトに保存されている文字列(UTF-8)を取得します key : キー名(UTF-8) 戻り値 : 取得した文字列へのポインタ (未設定の場合はnullptr)

§set_param_string: unsafe extern "C" fn(key: LPCSTR, value: LPCSTR)

プロジェクトに文字列(UTF-8)を保存します key : キー名(UTF-8) value : 保存する文字列(UTF-8)

§get_param_binary: unsafe extern "C" fn(key: LPCSTR, data: *mut c_void, size: i32) -> bool

プロジェクトに保存されているバイナリデータを取得します key : キー名(UTF-8) data : 取得するデータの格納先へのポインタ size : 取得するデータのサイズ (保存されているサイズと異なる場合は失敗します) 戻り値 : 正しく取得出来た場合はtrue

§set_param_binary: unsafe extern "C" fn(key: LPCSTR, data: *mut c_void, size: i32)

プロジェクトにバイナリデータを保存します key : キー名(UTF-8) data : 保存するデータへのポインタ size : 保存するデータのサイズ (4096バイト以下)

§clear_params: unsafe extern "C" fn()

プロジェクトに保存されているデータを全て削除します

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.