[][src]Trait object::read::ObjectSymbol

pub trait ObjectSymbol<'data>: Sealed {
    pub fn index(&self) -> SymbolIndex;
pub fn name(&self) -> Result<&'data str>;
pub fn address(&self) -> u64;
pub fn size(&self) -> u64;
pub fn kind(&self) -> SymbolKind;
pub fn section(&self) -> SymbolSection;
pub fn is_undefined(&self) -> bool;
pub fn is_definition(&self) -> bool;
pub fn is_common(&self) -> bool;
pub fn is_weak(&self) -> bool;
pub fn scope(&self) -> SymbolScope;
pub fn is_global(&self) -> bool;
pub fn is_local(&self) -> bool;
pub fn flags(&self) -> SymbolFlags<SectionIndex>; pub fn section_index(&self) -> Option<SectionIndex> { ... } }

A symbol table entry.

Required methods

pub fn index(&self) -> SymbolIndex[src]

The index of the symbol.

pub fn name(&self) -> Result<&'data str>[src]

The name of the symbol.

pub fn address(&self) -> u64[src]

The address of the symbol. May be zero if the address is unknown.

pub fn size(&self) -> u64[src]

The size of the symbol. May be zero if the size is unknown.

pub fn kind(&self) -> SymbolKind[src]

Return the kind of this symbol.

pub fn section(&self) -> SymbolSection[src]

Returns the section where the symbol is defined.

pub fn is_undefined(&self) -> bool[src]

Return true if the symbol is undefined.

pub fn is_definition(&self) -> bool[src]

Return true if the symbol is a definition of a function or data object that has a known address.

pub fn is_common(&self) -> bool[src]

Return true if the symbol is common data.

Note: does not check for SymbolSection::Section with SectionKind::Common.

pub fn is_weak(&self) -> bool[src]

Return true if the symbol is weak.

pub fn scope(&self) -> SymbolScope[src]

Returns the symbol scope.

pub fn is_global(&self) -> bool[src]

Return true if the symbol visible outside of the compilation unit.

This treats SymbolScope::Unknown as global.

pub fn is_local(&self) -> bool[src]

Return true if the symbol is only visible within the compilation unit.

pub fn flags(&self) -> SymbolFlags<SectionIndex>[src]

Symbol flags that are specific to each file format.

Loading content...

Provided methods

pub fn section_index(&self) -> Option<SectionIndex>[src]

Returns the section index for the section containing this symbol.

May return None if the symbol is not defined in a section.

Loading content...

Implementors

impl<'data, 'file> ObjectSymbol<'data> for CoffSymbol<'data, 'file>[src]

impl<'data, 'file> ObjectSymbol<'data> for Symbol<'data, 'file>[src]

impl<'data, 'file, Elf: FileHeader> ObjectSymbol<'data> for ElfSymbol<'data, 'file, Elf>[src]

impl<'data, 'file, Mach: MachHeader> ObjectSymbol<'data> for MachOSymbol<'data, 'file, Mach>[src]

Loading content...