MCPcopy Create free account
hub / github.com/Vector35/binaryninja-api / data

Method data

view/sharedcache/ui/symboltable.cpp:34–63  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

32
33
34QVariant SymbolTableModel::data(const QModelIndex& index, int role) const {
35 if (!index.isValid() || (role != Qt::DisplayRole && role != Qt::FontRole)) {
36 return QVariant();
37 }
38
39 switch (role)
40 {
41 case Qt::DisplayRole:
42 {
43 auto symbol = symbolAt(index.row());
44 auto symbolType = GetSymbolTypeAsString(symbol.type);
45
46 switch (index.column())
47 {
48 case 0: // Address column
49 return QString("0x%1").arg(symbol.address, 0, 16); // Display address as hexadecimal
50 case 1: // Type column
51 return QString::fromUtf8(symbolType.c_str(), symbolType.size());
52 case 2: // Name column
53 return QString::fromUtf8(symbol.name.c_str(), symbol.name.size());
54 default:
55 return QVariant();
56 }
57 }
58 case Qt::FontRole:
59 return m_font;
60 default:
61 return QVariant();
62 }
63}
64
65
66QVariant SymbolTableModel::headerData(int section, Qt::Orientation orientation, int role) const {

Callers 15

SerializeFunction · 0.45
DeserializeFunction · 0.45
BNKCViewGetInstallNamesFunction · 0.45
DeserializeFunction · 0.45
paintMethod · 0.45
setFilterMethod · 0.45
kctriage.hFile · 0.45
setImageLoadedMethod · 0.45
initImageTableMethod · 0.45
initSymbolTableMethod · 0.45
MachoViewMethod · 0.45
ReadStringTableMethod · 0.45

Calls 2

c_strMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected