OpenCoverage

qv4datacollector.h

Absolute File Name:/home/opencoverage/opencoverage/guest-scripts/qtdeclarative/src/qtdeclarative/src/plugins/qmltooling/qmldbg_debugger/qv4datacollector.h
Switch to Source codePreprocessed file
LineSourceCount
1-
2-
3-
4-
5-
6class QV4Debugger;-
7class QV4DataCollector-
8{-
9public:-
10 typedef uint Ref;-
11 typedef QVector<uint> Refs;-
12-
13 static QV4::Heap::ExecutionContext *findScope(QV4::Heap::ExecutionContext *ctxt, int scope);-
14 static int encodeScopeType(QV4::Heap::ExecutionContext::ContextType scopeType);-
15-
16 QVector<QV4::Heap::ExecutionContext::ContextType> getScopeTypes(int frame);-
17 QV4::Heap::ExecutionContext *findContext(int frame);-
18 QV4::CppStackFrame *findFrame(int frame);-
19-
20 QV4DataCollector(QV4::ExecutionEngine *engine);-
21-
22 Ref collect(const QV4::ScopedValue &value);-
23 Ref addFunctionRef(const QString &functionName);-
24 Ref addScriptRef(const QString &scriptName);-
25-
26 void setNamesAsObjects(bool namesAsObjects) { m_namesAsObjects = namesAsObjects; }
never executed: end of block
0
27 bool namesAsObjects() const { return
never executed: return m_namesAsObjects;
m_namesAsObjects;
never executed: return m_namesAsObjects;
}
0
28-
29 void setRedundantRefs(bool redundantRefs) { m_redundantRefs = redundantRefs; }
executed 26 times by 1 test: end of block
Executed by:
  • tst_qv4debugger
26
30 bool redundantRefs() const { return
executed 230 times by 1 test: return m_redundantRefs;
Executed by:
  • tst_qv4debugger
m_redundantRefs;
executed 230 times by 1 test: return m_redundantRefs;
Executed by:
  • tst_qv4debugger
}
230
31-
32 bool isValidRef(Ref ref) const;-
33 QJsonObject lookupRef(Ref ref, bool deep);-
34-
35 bool collectScope(QJsonObject *dict, int frameNr, int scopeNr);-
36 QJsonObject buildFrame(const QV4::StackFrame &stackFrame, int frameNr);-
37-
38 QV4::ExecutionEngine *engine() const { return
executed 4432 times by 2 tests: return m_engine;
Executed by:
  • tst_qqmldebugjs
  • tst_qv4debugger
m_engine;
executed 4432 times by 2 tests: return m_engine;
Executed by:
  • tst_qqmldebugjs
  • tst_qv4debugger
}
4432
39 QJsonArray flushCollectedRefs();-
40 void clear();-
41-
42private:-
43 Ref addRef(QV4::Value value, bool deduplicate = true);-
44 QV4::ReturnedValue getValue(Ref ref);-
45 bool lookupSpecialRef(Ref ref, QJsonObject *dict);-
46-
47 QJsonArray collectProperties(const QV4::Object *object);-
48 QJsonObject collectAsJson(const QString &name, const QV4::ScopedValue &value);-
49 void collectArgumentsInContext();-
50-
51 QV4::ExecutionEngine *m_engine;-
52 Refs m_collectedRefs;-
53 QV4::PersistentValue m_values;-
54 typedef QHash<Ref, QJsonObject> SpecialRefs;-
55 SpecialRefs m_specialRefs;-
56 bool m_namesAsObjects;-
57 bool m_redundantRefs;-
58};-
59-
60-
Switch to Source codePreprocessed file

Generated by Squish Coco 4.2.0