Public Member Functions

# BinNavi.API.disassembly.View2D Class Reference

Represents a single drawable view. More...

List of all members.

## Public Member Functions
void | addListener (final IView2DListener listener)
| Adds a View2D listener.
void | doCircularLayout ()
void | doHierarchicalLayout ()
void | doOrthogonalLayout ()
ViewContainer | getContainer ()
View | getView ()
| View that contains the raw data for the View2D.
void | removeListener (final IView2DListener listener)
| Removes a View2D listener.
void | save () throws CouldntSaveDataException
| Saves the view to the database.
void | saveAs (final String name, final String description) throws CouldntSaveDataException
| Saves a copy of the view to the database.
void | setProximityBrowsing (final boolean active)
| Toggles proximity browsing.
String | toString ()
| Printable representation of the view.
void | updateUI ()
| Repaints the view.
void | zoomToScreen ()
| Zooms graph to screen.

## Detailed Description

The graphical representation of a view. View2D objects represent the graphs shown in graph windows.

## Member Function Documentation

void BinNavi.API.disassembly.View2D.addListener | ( | final IView2DListener | listener | ) |

Adds an object that is notified about changes in the view.

Parameters:

  | listener | The listener object that is notified about changes in the view.

Exceptions:

  | IllegalArgumentException | Thrown if the listener argument is null.
  | IllegalStateException | Thrown if the listener object is already listening on the view.

void BinNavi.API.disassembly.View2D.doCircularLayout | ( |  | ) |

Layouts the graph using a circular layout.

void BinNavi.API.disassembly.View2D.doHierarchicalLayout | ( |  | ) |

Layouts the graph using a hierarchical layout.

void BinNavi.API.disassembly.View2D.doOrthogonalLayout | ( |  | ) |

Layouts the graph using an orthogonal layout.

ViewContainer BinNavi.API.disassembly.View2D.getContainer | ( |  | ) |

Returns the container in whose context the view is opened.

Returns:
  The container in whose context the view is opened.

View BinNavi.API.disassembly.View2D.getView | ( |  | ) |

Returns the view that provides the underlying data used to build the visible graph.

Returns:
  The view used to build the graph.

void BinNavi.API.disassembly.View2D.removeListener | ( | final IView2DListener | listener | ) |

Removes a listener object from the view.

Parameters:

  | listener | The listener object to remove from the view.

Exceptions:

  | IllegalArgumentException | Thrown if the listener argument is null.
  | IllegalStateException | Thrown if the listener object was not listening on the view.

void BinNavi.API.disassembly.View2D.save | ( |  | ) | throws CouldntSaveDataException

Saves the view to the database. Note that only non-native views can be saved. For native views please see saveAs.

Exceptions:

  | CouldntSaveDataException | Thrown if the view could not be saved to the database.

void BinNavi.API.disassembly.View2D.saveAs | ( | final String | name,
|  | final String | description |
| ) |  |  | throws CouldntSaveDataException

Saves a copy of the view to the database.

Parameters:

  | name | The name of the copied view.
  | description | The description of the copied view.

Exceptions:

  | CouldntSaveDataException | Thrown if the view could not be saved to the database.

void BinNavi.API.disassembly.View2D.setProximityBrowsing | ( | final boolean | active | ) |

Toggles between enabled and disabled proximity browsing.

Parameters:

  | active | True, if proximity browsing should be enabled. False, otherwise.

String BinNavi.API.disassembly.View2D.toString | ( |  | ) |

Returns the string representation of the view.

Returns:
  The string representation of the view.

void BinNavi.API.disassembly.View2D.updateUI | ( |  | ) |

Repaints the graph. This is useful after the graph was modified.

void BinNavi.API.disassembly.View2D.zoomToScreen | ( |  | ) |

Zooms the view in such a way that the whole graph is visible.