pub struct SavedState { /* private fields */ }Implementations§
Source§impl SavedState
impl SavedState
pub fn from_bytes(bytes: impl Into<Vec<u8>>) -> Result<Self>
pub fn from_file(path: impl AsRef<Path>) -> Result<Self>
pub fn header(&self) -> StateHeader
pub fn metadata(&self) -> &Value
pub fn encoded_bytes(&self) -> &[u8] ⓘ
pub fn decoded_bytes(&self) -> &[u8] ⓘ
pub fn is_compressed(&self) -> bool
pub fn source(&self) -> Option<&Path>
pub fn buffer_count(&self) -> usize
pub fn memory_bytes(&self) -> Option<u64>
Sourcepub fn cpu_state_and_buffers(&self) -> Result<(Value, Vec<Vec<u8>>)>
pub fn cpu_state_and_buffers(&self) -> Result<(Value, Vec<Vec<u8>>)>
Return the raw v86 state array and typed buffers in buffer_id order. The buffers are copied out of the decoded state so callers can safely hand them to a native backend with its own lifetime.
pub fn sha256(&self) -> String
pub fn summary(&self) -> StateSummary
pub fn write_decoded(&self, path: impl AsRef<Path>) -> Result<()>
Trait Implementations§
Source§impl Clone for SavedState
impl Clone for SavedState
Source§fn clone(&self) -> SavedState
fn clone(&self) -> SavedState
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for SavedState
impl RefUnwindSafe for SavedState
impl Send for SavedState
impl Sync for SavedState
impl Unpin for SavedState
impl UnsafeUnpin for SavedState
impl UnwindSafe for SavedState
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