retdec
symbol.h
Go to the documentation of this file.
1 
7 #ifndef FILEINFO_FILE_INFORMATION_FILE_INFORMATION_TYPES_SYMBOL_TABLE_SYMBOL_H
8 #define FILEINFO_FILE_INFORMATION_FILE_INFORMATION_TYPES_SYMBOL_TABLE_SYMBOL_H
9 
10 #include <limits>
11 #include <string>
12 
13 namespace retdec {
14 namespace fileinfo {
15 
21 class Symbol
22 {
23  private:
24  std::string name;
25  std::string type;
26  std::string bind;
27  std::string other;
28  std::string linkToSection;
29  unsigned long long index = std::numeric_limits<unsigned long long>::max();
30  unsigned long long value = std::numeric_limits<unsigned long long>::max();
31  unsigned long long address = std::numeric_limits<unsigned long long>::max();
32  unsigned long long size = std::numeric_limits<unsigned long long>::max();
33  public:
36  std::string getName() const;
37  std::string getType() const;
38  std::string getBind() const;
39  std::string getOther() const;
40  std::string getLinkToSection() const;
41  std::string getIndexStr() const;
42  std::string getValueStr() const;
43  std::string getAddressStr(std::ios_base &(* format)(std::ios_base &)) const;
44  std::string getSizeStr() const;
46 
49  void setName(std::string symbolName);
50  void setType(std::string symbolType);
51  void setBind(std::string symbolBind);
52  void setOther(std::string otherInformation);
53  void setLinkToSection(std::string link);
54  void setIndex(unsigned long long symbolIndex);
55  void setValue(unsigned long long symbolValue);
56  void setAddress(unsigned long long addressValue);
57  void setSize(unsigned long long symbolSize);
59 };
60 
61 } // namespace fileinfo
62 } // namespace retdec
63 
64 #endif
Definition: symbol.h:22
void setAddress(unsigned long long addressValue)
Definition: symbol.cpp:162
std::string name
name of symbol
Definition: symbol.h:24
std::string getLinkToSection() const
Definition: symbol.cpp:53
void setBind(std::string symbolBind)
Definition: symbol.cpp:117
unsigned long long size
size associated with symbol
Definition: symbol.h:32
std::string other
other information
Definition: symbol.h:27
void setValue(unsigned long long symbolValue)
Definition: symbol.cpp:153
void setOther(std::string otherInformation)
Definition: symbol.cpp:126
std::string linkToSection
link to associated section
Definition: symbol.h:28
std::string getName() const
Definition: symbol.cpp:17
std::string getIndexStr() const
Definition: symbol.cpp:62
void setType(std::string symbolType)
Definition: symbol.cpp:108
std::string getOther() const
Definition: symbol.cpp:44
void setIndex(unsigned long long symbolIndex)
Definition: symbol.cpp:144
void setName(std::string symbolName)
Definition: symbol.cpp:99
unsigned long long index
index of symbol in symbol table
Definition: symbol.h:29
std::string getType() const
Definition: symbol.cpp:26
std::string getSizeStr() const
Definition: symbol.cpp:90
std::string getValueStr() const
Definition: symbol.cpp:71
unsigned long long value
value of symbol
Definition: symbol.h:30
void setSize(unsigned long long symbolSize)
Definition: symbol.cpp:171
std::string bind
symbol bind
Definition: symbol.h:26
std::string getBind() const
Definition: symbol.cpp:35
void setLinkToSection(std::string link)
Definition: symbol.cpp:135
unsigned long long address
symbol address
Definition: symbol.h:31
std::string type
type of symbol
Definition: symbol.h:25
std::string getAddressStr(std::ios_base &(*format)(std::ios_base &)) const
Definition: symbol.cpp:81
Definition: archive_wrapper.h:19