LLVM 17.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)
 
std::optional< unsignedgetAttributeValue (unsigned tag) const
 
std::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)
 
void setAttributeString (unsigned tag, StringRef value)
 

Protected Attributes

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

Detailed Description

Definition at line 25 of file ELFAttributeParser.h.

Constructor & Destructor Documentation

◆ ~ELFAttributeParser()

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

Definition at line 51 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 55 of file ELFAttributeParser.h.

◆ ELFAttributeParser() [2/2]

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

Definition at line 58 of file ELFAttributeParser.h.

Member Function Documentation

◆ getAttributeString()

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

Definition at line 69 of file ELFAttributeParser.h.

References I.

◆ getAttributeValue()

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

Definition at line 63 of file ELFAttributeParser.h.

References attributes, and I.

◆ 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

◆ 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

◆ setAttributeString()

void llvm::ELFAttributeParser::setAttributeString ( unsigned  tag,
StringRef  value 
)
inlineprotected

Definition at line 46 of file ELFAttributeParser.h.

References value.

Referenced by stringAttribute().

◆ stringAttribute()

Error ELFAttributeParser::stringAttribute ( unsigned  tag)

Member Data Documentation

◆ cursor

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

◆ de

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

◆ sw

ScopedPrinter* llvm::ELFAttributeParser::sw
protected

◆ tagToStringMap

TagNameMap llvm::ELFAttributeParser::tagToStringMap
protected

Definition at line 34 of file ELFAttributeParser.h.

Referenced by integerAttribute(), printAttribute(), and stringAttribute().


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