Struct simics_api_sys::bindings::save_state_interface
source · #[repr(C)]pub struct save_state_interface {
pub get_version: Option<unsafe extern "C" fn(obj: *mut conf_object) -> c_int>,
pub get_size: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t) -> c_int>,
pub get_align: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t) -> c_int>,
pub save_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, dest: *mut c_void) -> c_int>,
pub load_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>,
pub compare_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>,
pub print_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void, symnames: c_int, diff: c_int) -> c_int>,
pub save_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, dest: *mut c_void) -> c_int>,
pub load_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>,
pub compare_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>,
pub print_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void, symnames: c_int, diff: c_int) -> c_int>,
}
Fields§
§get_version: Option<unsafe extern "C" fn(obj: *mut conf_object) -> c_int>
return the CVS version of the object
get_size: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t) -> c_int>
return the size needed for the current state
get_align: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t) -> c_int>
return the alignment needed for the structure
save_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, dest: *mut c_void) -> c_int>
save the state in dest. dest must contains enough space (get_size with the same parameter should return the size needed)
load_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>
load the state from src
compare_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>
compare the state and return 0 if the same
print_state: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void, symnames: c_int, diff: c_int) -> c_int>
compare the state and return 0 if the same. print out all/the difference according to flags
save_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, dest: *mut c_void) -> c_int>
host-endian functions (eventually faster, not mandatory)
load_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>
§compare_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void) -> c_int>
§print_state_he: Option<unsafe extern "C" fn(obj: *mut conf_object, stype: state_save_kind_t, src: *mut c_void, symnames: c_int, diff: c_int) -> c_int>
Trait Implementations§
source§impl Clone for save_state_interface
impl Clone for save_state_interface
source§fn clone(&self) -> save_state_interface
fn clone(&self) -> save_state_interface
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for save_state_interface
impl Debug for save_state_interface
source§impl Default for save_state_interface
impl Default for save_state_interface
source§fn default() -> save_state_interface
fn default() -> save_state_interface
Returns the “default value” for a type. Read more
source§impl Hash for save_state_interface
impl Hash for save_state_interface
source§impl Ord for save_state_interface
impl Ord for save_state_interface
source§fn cmp(&self, other: &save_state_interface) -> Ordering
fn cmp(&self, other: &save_state_interface) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for save_state_interface
impl PartialEq for save_state_interface
source§impl PartialOrd for save_state_interface
impl PartialOrd for save_state_interface
impl Copy for save_state_interface
impl Eq for save_state_interface
impl StructuralPartialEq for save_state_interface
Auto Trait Implementations§
impl Freeze for save_state_interface
impl RefUnwindSafe for save_state_interface
impl Send for save_state_interface
impl Sync for save_state_interface
impl Unpin for save_state_interface
impl UnwindSafe for save_state_interface
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)