Struct symbolic_debuginfo::Archive [−][src]
A generic archive that can contain one or more object files.
Effectively, this will only contain a single object for all file types other than MachO
. Mach
objects can either be single object files or so-called fat files that contain multiple objects
per architecture.
Implementations
impl<'d> Archive<'d>
[src]
pub fn test(data: &[u8]) -> bool
[src]
Tests whether this buffer contains a valid object archive.
pub fn peek(data: &[u8]) -> FileFormat
[src]
Tries to infer the object archive type from the start of the given buffer.
pub fn parse(data: &'d [u8]) -> Result<Self, ObjectError>
[src]
Tries to parse a generic archive from the given slice.
pub fn file_format(&self) -> FileFormat
[src]
The container format of this file.
pub fn objects(&self) -> ObjectIterator<'d, '_>ⓘNotable traits for ObjectIterator<'d, 'a>
impl<'d, 'a> Iterator for ObjectIterator<'d, 'a> type Item = Result<Object<'d>, ObjectError>;
[src]
Notable traits for ObjectIterator<'d, 'a>
impl<'d, 'a> Iterator for ObjectIterator<'d, 'a> type Item = Result<Object<'d>, ObjectError>;
Returns an iterator over all objects contained in this archive.
pub fn object_count(&self) -> usize
[src]
Returns the number of objects in this archive.
pub fn object_by_index(
&self,
index: usize
) -> Result<Option<Object<'d>>, ObjectError>
[src]
&self,
index: usize
) -> Result<Option<Object<'d>>, ObjectError>
Resolves the object at the given index.
Returns Ok(None)
if the index is out of bounds, or Err
if the object exists but cannot
be parsed.
pub fn is_multi(&self) -> bool
[src]
Returns whether this is a multi-object archive.
This may also return true if there is only a single object inside the archive.
Trait Implementations
impl<'slf, 'd: 'slf> AsSelf<'slf> for Archive<'d>
[src]
type Ref = Archive<'slf>
The Self
type with 'slf
lifetimes, returned by as_self
.
fn as_self(&'slf self) -> &Self::Ref
[src]
impl<'d> Debug for Archive<'d>
[src]
Auto Trait Implementations
impl<'d> !RefUnwindSafe for Archive<'d>
impl<'d> Send for Archive<'d>
impl<'d> Sync for Archive<'d>
impl<'d> Unpin for Archive<'d>
impl<'d> !UnwindSafe for Archive<'d>
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,
pub 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.
pub 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>,