Offers convenience functions for working with view graphs. More...
Static Public Member Functions | |
| static CodeNode | getCodeNode (final ViewGraph graph, final Address address) |
| Finds a code node with a given address. | |
| static CodeNode | getCodeNode (final ViewGraph graph, final long address) |
| Finds a code node with given address. | |
| static List< CodeNode > | getCodeNodes (final ViewGraph graph) |
| Returns the code nodes of the graph. | |
| static FunctionNode | getFunctionNode (final ViewGraph graph, final String functionName) |
| Finds the function node with a given function name. | |
| static List< FunctionNode > | getFunctionNodes (final ViewGraph graph) |
| Returns the function nodes of a graph. | |
| static Instruction | getInstruction (final ViewGraph graph, final Address address) |
| Finds an instruction with a given address. | |
| static Instruction | getInstruction (final ViewGraph graph, final long address) |
| Finds an instruction with a given address. | |
| static InliningResult | inlineFunctionCall (final View view, final CodeNode codeNode, final Instruction instruction, final Function function) |
| Inlines a function call into a code node. | |
Offers convenience functions for working with view graphs. Please note that many convenience functions are just straight-forward implementations of commonly used algorithms and therefore can have significant runtime costs.
| static CodeNode BinNavi.API.disassembly.ViewGraphHelpers.getCodeNode | ( | final ViewGraph | graph, | |
| final Address | address | |||
| ) | [static] |
Returns the code node of a view graph that starts at a given address. Since addresses do not uniquely identify code nodes it is possible that there is more than one code node with the given address in the graph. In case of multiple code nodes that start at the given address it is undefined exactly which of those code nodes is returned.
This function is guaranteed to work in O(n) where n is the number of nodes in the graph.
| graph | The graph to search through. | |
| address | The address to search for. |
| static CodeNode BinNavi.API.disassembly.ViewGraphHelpers.getCodeNode | ( | final ViewGraph | graph, | |
| final long | address | |||
| ) | [static] |
Returns the code node of a view graph that starts at a given address. Since addresses do not uniquely identify code nodes it is possible that there is more than one code node with the given address in the graph. In case of multiple code nodes that start at the given address it is undefined exactly which of those code nodes is returned.
This function is guaranteed to work in O(n) where n is the number of nodes in the graph.
| graph | The graph to search through. | |
| address | The address to search for. |
| static List<CodeNode> BinNavi.API.disassembly.ViewGraphHelpers.getCodeNodes | ( | final ViewGraph | graph | ) | [static] |
Returns a list of all code nodes of a graph.
This function is guaranteed to work in O(n) where n is the number of nodes in the graph.
| graph | The graph to search through. |
| static FunctionNode BinNavi.API.disassembly.ViewGraphHelpers.getFunctionNode | ( | final ViewGraph | graph, | |
| final String | functionName | |||
| ) | [static] |
Returns the function node of a view graph that represents a function of a given name. Since names do not uniquely identify function nodes it is possible that there is more than one function node with the given name in the graph. In case of multiple function nodes with that name it is undefined exactly which of those function nodes is returned.
This function is guaranteed to work in O(n) where n is the number of nodes in the graph.
| graph | The graph to search through. | |
| functionName | The name of the function to search for. |
| static List<FunctionNode> BinNavi.API.disassembly.ViewGraphHelpers.getFunctionNodes | ( | final ViewGraph | graph | ) | [static] |
Returns a list of all function nodes of a graph.
This function is guaranteed to work in O(n) where n is the number of nodes in the graph.
| graph | The graph to search through. |
| static Instruction BinNavi.API.disassembly.ViewGraphHelpers.getInstruction | ( | final ViewGraph | graph, | |
| final Address | address | |||
| ) | [static] |
Returns the instruction of a view graph that starts at a given address. Since addresses do not uniquely identify instructions it is possible that there is more than one instruction with the given address in the graph. In case of multiple instructions that start at the given address it is undefined exactly which of those instructions is returned.
This function is guaranteed to work in O(m + n) where m is the number of nodes in the graph and n is the number of instructions in the graph.
| graph | The graph to search through. | |
| address | The address to search for. |
| static Instruction BinNavi.API.disassembly.ViewGraphHelpers.getInstruction | ( | final ViewGraph | graph, | |
| final long | address | |||
| ) | [static] |
Returns the instruction of a view graph that starts at a given address. Since addresses do not uniquely identify instructions it is possible that there is more than one instruction with the given address in the graph. In case of multiple instructions that start at the given address it is undefined exactly which of those instructions is returned.
This function is guaranteed to work in O(m + n) where m is the number of nodes in the graph and n is the number of instructions in the graph.
| graph | The graph to search through. | |
| address | The address to search for. |
| static InliningResult BinNavi.API.disassembly.ViewGraphHelpers.inlineFunctionCall | ( | final View | view, | |
| final CodeNode | codeNode, | |||
| final Instruction | instruction, | |||
| final Function | function | |||
| ) | [static] |
Inserts the code nodes of a function into a view and splits an existing code node (if necessary) to call the function.
| view | The view where the inlining operation takes place. | |
| codeNode | The code node that is split. | |
| instruction | The sub-function call instruction. | |
| function | The function to be inlined. |
1.7.1