LLVM  14.0.0git
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
llvm::ELFAttributeParser Class Referenceabstract

#include "llvm/Support/ELFAttributeParser.h"

Inheritance diagram for llvm::ELFAttributeParser:
Inheritance graph
[legend]
Collaboration diagram for llvm::ELFAttributeParser:
Collaboration graph
[legend]

Public Member Functions

virtual ~ELFAttributeParser ()
 
Error integerAttribute (unsigned tag)
 
Error stringAttribute (unsigned tag)
 
 ELFAttributeParser (ScopedPrinter *sw, TagNameMap tagNameMap, StringRef vendor)
 
 ELFAttributeParser (TagNameMap tagNameMap, StringRef vendor)
 
Error parse (ArrayRef< uint8_t > section, support::endianness endian)
 
Optional< unsigned > getAttributeValue (unsigned tag) const
 
Optional< StringRefgetAttributeString (unsigned tag) const
 

Protected Member Functions

void printAttribute (unsigned tag, unsigned value, StringRef valueDesc)
 
Error parseStringAttribute (const char *name, unsigned tag, ArrayRef< const char * > strings)
 
Error parseAttributeList (uint32_t length)
 
void parseIndexList (SmallVectorImpl< uint8_t > &indexList)
 
Error parseSubsection (uint32_t length)
 

Protected Attributes

ScopedPrintersw
 
TagNameMap tagToStringMap
 
DataExtractor de {ArrayRef<uint8_t>{}, true, 0}
 
DataExtractor::Cursor cursor {0}
 

Detailed Description

Definition at line 23 of file ELFAttributeParser.h.

Constructor & Destructor Documentation

◆ ~ELFAttributeParser()

virtual llvm::ELFAttributeParser::~ELFAttributeParser ( )
inlinevirtual

Definition at line 45 of file ELFAttributeParser.h.

References cursor, and llvm::DataExtractor::Cursor::takeError().

◆ ELFAttributeParser() [1/2]

llvm::ELFAttributeParser::ELFAttributeParser ( ScopedPrinter sw,
TagNameMap  tagNameMap,
StringRef  vendor 
)
inline

Definition at line 49 of file ELFAttributeParser.h.

◆ ELFAttributeParser() [2/2]

llvm::ELFAttributeParser::ELFAttributeParser ( TagNameMap  tagNameMap,
StringRef  vendor 
)
inline

Definition at line 52 of file ELFAttributeParser.h.

Member Function Documentation

◆ getAttributeString()

Optional<StringRef> llvm::ELFAttributeParser::getAttributeString ( unsigned  tag) const
inline

Definition at line 63 of file ELFAttributeParser.h.

References I, and llvm::None.

◆ getAttributeValue()

Optional<unsigned> llvm::ELFAttributeParser::getAttributeValue ( unsigned  tag) const
inline

Definition at line 57 of file ELFAttributeParser.h.

References attributes, I, and llvm::None.

◆ integerAttribute()

Error ELFAttributeParser::integerAttribute ( unsigned  tag)

◆ parse()

Error ELFAttributeParser::parse ( ArrayRef< uint8_t >  section,
support::endianness  endian 
)

◆ parseAttributeList()

Error ELFAttributeParser::parseAttributeList ( uint32_t  length)
protected

◆ parseIndexList()

void ELFAttributeParser::parseIndexList ( SmallVectorImpl< uint8_t > &  indexList)
protected

Definition at line 87 of file ELFAttributeParser.cpp.

◆ parseStringAttribute()

Error ELFAttributeParser::parseStringAttribute ( const char *  name,
unsigned  tag,
ArrayRef< const char * >  strings 
)
protected

◆ parseSubsection()

Error ELFAttributeParser::parseSubsection ( uint32_t  length)
protected

◆ printAttribute()

void ELFAttributeParser::printAttribute ( unsigned  tag,
unsigned  value,
StringRef  valueDesc 
)
protected

◆ stringAttribute()

Error ELFAttributeParser::stringAttribute ( unsigned  tag)

Member Data Documentation

◆ cursor

DataExtractor::Cursor llvm::ELFAttributeParser::cursor {0}
protected

Definition at line 34 of file ELFAttributeParser.h.

Referenced by ~ELFAttributeParser().

◆ de

DataExtractor llvm::ELFAttributeParser::de {ArrayRef<uint8_t>{}, true, 0}
protected

Definition at line 33 of file ELFAttributeParser.h.

◆ sw

ScopedPrinter* llvm::ELFAttributeParser::sw
protected

Definition at line 31 of file ELFAttributeParser.h.

◆ tagToStringMap

TagNameMap llvm::ELFAttributeParser::tagToStringMap
protected

Definition at line 32 of file ELFAttributeParser.h.


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