[][src]Struct symbolic_debuginfo::Archive

pub struct Archive<'d>(_);

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.

Methods

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.

Important traits for ObjectIterator<'d, 'a>
pub fn objects(&self) -> ObjectIterator<'d, '_>[src]

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]

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.

Trait Implementations

impl<'d> Debug for Archive<'d>[src]

impl<'slf, 'd: 'slf> AsSelf<'slf> for Archive<'d>[src]

type Ref = Archive<'slf>

The Self type with 'slf lifetimes, returned by as_self.

Auto Trait Implementations

impl<'d> Send for Archive<'d>

impl<'d> Sync for Archive<'d>

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Erased for T