2009-09-17 13:06:04 +00:00
|
|
|
#ifndef SYMBOLTABLEENTRY_H
|
|
|
|
#define SYMBOLTABLEENTRY_H
|
|
|
|
|
|
|
|
#include "macho_global.h"
|
|
|
|
#include <mach-o/nlist.h>
|
|
|
|
class MachOFile;
|
|
|
|
|
2009-09-29 15:01:48 +00:00
|
|
|
class EXPORT SymbolTableEntry
|
2009-09-17 13:06:04 +00:00
|
|
|
{
|
|
|
|
public:
|
2016-11-19 16:23:39 +01:00
|
|
|
SymbolTableEntry(MachOFile& file, char* stringTable);
|
|
|
|
virtual ~SymbolTableEntry();
|
|
|
|
std::string getName(bool shouldDemangle) const;
|
2009-09-17 13:06:04 +00:00
|
|
|
|
2016-11-19 16:23:39 +01:00
|
|
|
enum Type {
|
|
|
|
TypeExported = 0,
|
|
|
|
TypeImported,
|
|
|
|
TypeLocal,
|
|
|
|
TypeDebug,
|
|
|
|
TypePrivateExtern,
|
|
|
|
NumTypes
|
|
|
|
};
|
2009-09-17 13:06:04 +00:00
|
|
|
|
2016-11-19 16:23:39 +01:00
|
|
|
Type getType() const;
|
|
|
|
virtual unsigned int getInternalType() const = 0;
|
|
|
|
virtual const char* getInternalName() const = 0;
|
2009-09-17 13:06:04 +00:00
|
|
|
|
|
|
|
protected:
|
2016-11-19 16:23:39 +01:00
|
|
|
MachOFile& file;
|
|
|
|
char* stringTable;
|
2009-09-17 13:06:04 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // SYMBOLTABLEENTRY_H
|