summaryrefslogtreecommitdiff
path: root/functiongraph.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'functiongraph.cpp')
-rw-r--r--functiongraph.cpp36
1 files changed, 36 insertions, 0 deletions
diff --git a/functiongraph.cpp b/functiongraph.cpp
index a743254e..9948d70e 100644
--- a/functiongraph.cpp
+++ b/functiongraph.cpp
@@ -186,3 +186,39 @@ void FunctionGraph::SetOption(BNDisassemblyOption option, bool state)
{
BNSetFunctionGraphOption(m_graph, option, state);
}
+
+
+bool FunctionGraph::IsILGraph() const
+{
+ return BNIsILFunctionGraph(m_graph);
+}
+
+
+bool FunctionGraph::IsLowLevelILGraph() const
+{
+ return BNIsLowLevelILFunctionGraph(m_graph);
+}
+
+
+bool FunctionGraph::IsMediumLevelILGraph() const
+{
+ return BNIsMediumLevelILFunctionGraph(m_graph);
+}
+
+
+Ref<LowLevelILFunction> FunctionGraph::GetLowLevelILFunction() const
+{
+ BNLowLevelILFunction* func = BNGetFunctionGraphLowLevelILFunction(m_graph);
+ if (!func)
+ return nullptr;
+ return new LowLevelILFunction(func);
+}
+
+
+Ref<MediumLevelILFunction> FunctionGraph::GetMediumLevelILFunction() const
+{
+ BNMediumLevelILFunction* func = BNGetFunctionGraphMediumLevelILFunction(m_graph);
+ if (!func)
+ return nullptr;
+ return new MediumLevelILFunction(func);
+}