Inherits com::google::security::zynamics::binnavi::APIHelpers::ApiObject< INaviFunction >.
List of all members.
Detailed Description
Function objects describe original functions from imported modules. This includes things like the name or the description of the function as well as the flowgraph of the function.
The structure of functions is immutable. That means the flowgraph of functions can not be modified. To modify the flowgraph of a function it is necessary to convert it to a View first.
Member Function Documentation
void com.google.security.zynamics.binnavi.API.disassembly.Function.addListener |
( |
final IFunctionListener |
listener |
) |
|
Adds an object that is notified about changes in the function.
- Parameters:
-
| listener | The listener object that is notified about changes in the function. |
- Exceptions:
-
| IllegalArgumentException | Thrown if the listener argument is null. |
| IllegalStateException | Thrown if the listener object is already listening on the function. |
Appends a global function comment to the function.
- Parameters:
-
| comment | The string of the comment to get appended. |
- Exceptions:
-
void com.google.security.zynamics.binnavi.API.disassembly.Function.close |
( |
|
) |
|
Delete a function comment.
- Parameters:
-
- Exceptions:
-
IComment com.google.security.zynamics.binnavi.API.disassembly.Function.editComment |
( |
final IComment |
comment, |
|
|
final String |
newComment | |
|
) |
| | throws CouldntSaveDataException |
Edit a function comment.
- Parameters:
-
| comment | The IComment which is edited. |
| newComment | The String to replace the current comment text. |
- Returns:
- The edited comment.
- Exceptions:
-
Address com.google.security.zynamics.binnavi.API.disassembly.Function.getAddress |
( |
|
) |
|
Returns the start address of the function.
- Returns:
- The start address of the function.
int com.google.security.zynamics.binnavi.API.disassembly.Function.getBlockCount |
( |
|
) |
|
Returns the number of basic blocks in the function. This function can be called if the function has not yet been loaded.
- Returns:
- The number of basic blocks in the function.
List<IComment> com.google.security.zynamics.binnavi.API.disassembly.Function.getComment |
( |
|
) |
|
Returns the function comment. This is the comment that is shown as the global comment in views that show function nodes.
- Returns:
- The function comment.
String com.google.security.zynamics.binnavi.API.disassembly.Function.getDescription |
( |
|
) |
|
Returns the description of the function. This is the string that is shown as the description of the function in the main window.
- Returns:
- The function description.
int com.google.security.zynamics.binnavi.API.disassembly.Function.getEdgeCount |
( |
|
) |
|
Returns the number of edges in the function. This function can be called if the function has not yet been loaded.
- Returns:
- The number of edges in the view.
FlowGraph com.google.security.zynamics.binnavi.API.disassembly.Function.getGraph |
( |
|
) |
|
Returns the flowgraph of the function. This graph contains the basic blocks of the function and edges that show how control flow can propagate through the function.
- Returns:
- The flowgraph of the function.
- Exceptions:
-
| IllegalStateException | Thrown if the function is not loaded. |
Module com.google.security.zynamics.binnavi.API.disassembly.Function.getModule |
( |
|
) |
|
Returns the module the function belongs to.
- Returns:
- The module the function belongs to.
String com.google.security.zynamics.binnavi.API.disassembly.Function.getName |
( |
|
) |
|
Returns the name of the function.
- Returns:
- The name of the function.
Converts the View to REIL code. This function can only be used if the view has already been loaded.
Using this function over manual translation via ReilTranslator has the advantage that REIL translation results are automatically cached. Subsequent uses of this function requires no additional re-translation of the view provided that nothing relevant (like added/removed code nodes) changed.
- Returns:
- The REIL representation of the view.
- Exceptions:
-
| InternalTranslationException | Thrown if the REIL translation failed. |
FunctionType com.google.security.zynamics.binnavi.API.disassembly.Function.getType |
( |
|
) |
|
Returns the type of the function.
- Returns:
- The type of the function.
boolean com.google.security.zynamics.binnavi.API.disassembly.Function.isLoaded |
( |
|
) |
|
Returns a flag that indicates whether the function is loaded.
- Returns:
- True, if the function is loaded. False, otherwise.
Loads the function data from the database.
- Exceptions:
-
| IllegalStateException | Thrown if the function is already loaded. |
| CouldntLoadDataException | Thrown if the function data could not be loaded from the database. |
void com.google.security.zynamics.binnavi.API.disassembly.Function.removeListener |
( |
final IFunctionListener |
listener |
) |
|
Removes a listener object from the function.
- Parameters:
-
| listener | The listener object to remove from the function. |
- Exceptions:
-
| IllegalArgumentException | Thrown if the listener argument is null. |
| IllegalStateException | Thrown if the listener object was not listening on the function. |
void com.google.security.zynamics.binnavi.API.disassembly.Function.setComment |
( |
final ArrayList< IComment > |
comment |
) |
throws CouldntSaveDataException |
Changes the comment of the function. This is the comment that is shown as the global comment in views that show function nodes.
- Parameters:
-
| comment | The new value of the comment. |
- Exceptions:
-
| IllegalArgumentException | Thrown if the comment argument is null. |
| CouldntSaveDataException | Thrown if the comment could not be changed. |
void com.google.security.zynamics.binnavi.API.disassembly.Function.setDescription |
( |
final String |
description |
) |
throws CouldntSaveDataException |
Changes the description of the function.
- Parameters:
-
| description | The new value of the description. |
- Exceptions:
-
| IllegalArgumentException | Thrown if the description argument is null. |
| CouldntSaveDataException | Thrown if the description could not be changed. |
void com.google.security.zynamics.binnavi.API.disassembly.Function.setName |
( |
final String |
name |
) |
throws CouldntSaveDataException |
Changes the name of the function.
- Parameters:
-
| name | The new value of the name. |
- Exceptions:
-
| IllegalArgumentException | Thrown if the name argument is null. |
| CouldntSaveDataException | Thrown if the name could not be changed. |
String com.google.security.zynamics.binnavi.API.disassembly.Function.toString |
( |
|
) |
|
Returns the string representation of the function.
- Returns:
- The string representation of the function.