LLVM  6.0.0svn
Classes | Public Types | Public Member Functions | Static Public Member Functions | List of all members
llvm::object::Archive Class Reference

#include "llvm/Object/Archive.h"

Inheritance diagram for llvm::object::Archive:
Inheritance graph
Collaboration diagram for llvm::object::Archive:
Collaboration graph


class  Child
class  child_iterator
class  Symbol
class  symbol_iterator

Public Types

enum  Kind {

Public Member Functions

 Archive (MemoryBufferRef Source, Error &Err)
Kind kind () const
bool isThin () const
child_iterator child_begin (Error &Err, bool SkipInternal=true) const
child_iterator child_end () const
iterator_range< child_iteratorchildren (Error &Err, bool SkipInternal=true) const
symbol_iterator symbol_begin () const
symbol_iterator symbol_end () const
iterator_range< symbol_iteratorsymbols () const
Expected< Optional< Child > > findSym (StringRef name) const
bool isEmpty () const
bool hasSymbolTable () const
StringRef getSymbolTable () const
StringRef getStringTable () const
uint32_t getNumberOfSymbols () const
std::vector< std::unique_ptr< MemoryBuffer > > takeThinBuffers ()
- Public Member Functions inherited from llvm::object::Binary
 Binary ()=delete
 Binary (const Binary &other)=delete
virtual ~Binary ()
StringRef getData () const
StringRef getFileName () const
MemoryBufferRef getMemoryBufferRef () const
unsigned int getType () const
bool isObject () const
bool isSymbolic () const
bool isArchive () const
bool isMachOUniversalBinary () const
bool isELF () const
bool isMachO () const
bool isCOFF () const
bool isWasm () const
bool isCOFFImportFile () const
bool isIR () const
bool isLittleEndian () const
bool isWinRes () const
Triple::ObjectFormatType getTripleObjectFormat () const

Static Public Member Functions

static Expected< std::unique_ptr< Archive > > create (MemoryBufferRef Source)
static bool classof (Binary const *v)
- Static Public Member Functions inherited from llvm::object::Binary
static std::error_code checkOffset (MemoryBufferRef M, uintptr_t Addr, const uint64_t Size)

Additional Inherited Members

- Protected Types inherited from llvm::object::Binary
enum  {
  ID_Archive, ID_MachOUniversalBinary, ID_COFFImportFile, ID_IR,
  ID_WinRes, ID_StartObjects, ID_COFF, ID_ELF32L,
  ID_ELF32B, ID_ELF64L, ID_ELF64B, ID_MachO32L,
  ID_MachO32B, ID_MachO64L, ID_MachO64B, ID_Wasm,
- Protected Member Functions inherited from llvm::object::Binary
 Binary (unsigned int Type, MemoryBufferRef Source)
- Static Protected Member Functions inherited from llvm::object::Binary
static unsigned int getELFType (bool isLE, bool is64Bits)
static unsigned int getMachOType (bool isLE, bool is64Bits)
- Protected Attributes inherited from llvm::object::Binary
MemoryBufferRef Data

Detailed Description

Definition at line 84 of file Archive.h.

Member Enumeration Documentation

◆ Kind


Definition at line 230 of file Archive.h.

Constructor & Destructor Documentation

◆ Archive()

Archive::Archive ( MemoryBufferRef  Source,
Error Err 

Member Function Documentation

◆ child_begin()

Archive::child_iterator Archive::child_begin ( Error Err,
bool  SkipInternal = true 
) const

◆ child_end()

Archive::child_iterator Archive::child_end ( ) const

◆ children()

iterator_range<child_iterator> llvm::object::Archive::children ( Error Err,
bool  SkipInternal = true 
) const

Definition at line 244 of file Archive.h.

References llvm::make_range().

◆ classof()

static bool llvm::object::Archive::classof ( Binary const v)

Definition at line 256 of file Archive.h.

References llvm::object::Binary::isArchive(), and name.

◆ create()

Expected< std::unique_ptr< Archive > > Archive::create ( MemoryBufferRef  Source)

◆ findSym()

Expected< Optional< Archive::Child > > Archive::findSym ( StringRef  name) const

◆ getNumberOfSymbols()

uint32_t Archive::getNumberOfSymbols ( ) const

◆ getStringTable()

StringRef llvm::object::Archive::getStringTable ( ) const

Definition at line 266 of file Archive.h.

Referenced by llvm::object::ArchiveMemberHeader::getName().

◆ getSymbolTable()

StringRef llvm::object::Archive::getSymbolTable ( ) const

Definition at line 265 of file Archive.h.

Referenced by getNumberOfSymbols(), and symbol_begin().

◆ hasSymbolTable()

bool Archive::hasSymbolTable ( ) const

Definition at line 993 of file Archive.cpp.

References llvm::StringRef::empty().

Referenced by getNumberOfSymbols(), and symbol_begin().

◆ isEmpty()

bool Archive::isEmpty ( ) const

Definition at line 991 of file Archive.cpp.

References llvm::object::Binary::Data, and llvm::MemoryBufferRef::getBufferSize().

Referenced by child_begin().

◆ isThin()

bool llvm::object::Archive::isThin ( ) const

◆ kind()

Kind llvm::object::Archive::kind ( ) const

◆ symbol_begin()

Archive::symbol_iterator Archive::symbol_begin ( ) const

◆ symbol_end()

Archive::symbol_iterator Archive::symbol_end ( ) const

Definition at line 952 of file Archive.cpp.

References getNumberOfSymbols(), and llvm::ARMBuildAttrs::Symbol.

Referenced by findSym().

◆ symbols()

iterator_range<symbol_iterator> llvm::object::Archive::symbols ( ) const

Definition at line 251 of file Archive.h.

References llvm::make_range().

◆ takeThinBuffers()

std::vector<std::unique_ptr<MemoryBuffer> > llvm::object::Archive::takeThinBuffers ( )

Definition at line 269 of file Archive.h.

References C, and llvm::Format.

The documentation for this class was generated from the following files: