[−]Struct symbolic::minidump::cfi::CfiCache
A cache file for call frame information (CFI).
The default way to use this cache is to construct it from an Object
and save it to a file.
Then, load it from the file and pass it to the minidump processor.
use std::fs::File; use symbolic_common::ByteView; use symbolic_debuginfo::Object; use symbolic_minidump::cfi::CfiCache; let view = ByteView::open("/path/to/object")?; let object = Object::parse(&view)?; let cache = CfiCache::from_object(&object)?; cache.write_to(File::create("my.cficache")?)?;
use symbolic_common::ByteView; use symbolic_minidump::cfi::CfiCache; let view = ByteView::open("my.cficache")?; let cache = CfiCache::from_bytes(view)?;
Implementations
impl CfiCache<'static>
pub fn from_object(object: &Object) -> Result<CfiCache<'static>, CfiError>
Construct a CFI cache from an Object
.
impl<'a> CfiCache<'a>
pub fn from_bytes(byteview: ByteView<'a>) -> Result<CfiCache<'a>, CfiError>
Load a symcache from a ByteView
.
pub fn version(&self) -> u32
Returns the cache file format version.
pub fn is_latest(&self) -> bool
Returns whether this cache is up-to-date.
pub fn as_slice(&self) -> &[u8]
Returns the raw buffer of the cache file.
pub fn write_to<W>(&self, writer: W) -> Result<(), Error> where
W: Write,
W: Write,
Writes the cache to the given writer.
Auto Trait Implementations
impl<'a> RefUnwindSafe for CfiCache<'a>
impl<'a> Send for CfiCache<'a>
impl<'a> Sync for CfiCache<'a>
impl<'a> Unpin for CfiCache<'a>
impl<'a> UnwindSafe for CfiCache<'a>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,