com.virtuosotechnologies.asaph.maingui
Interface DatabaseHandler


public interface DatabaseHandler

Implement this interface to handle events related to an opened database


Method Summary
 boolean handleDatabaseClosing()
          This method is called when the main gui wants to close this database.
 boolean handleDatabaseDirtied()
          This is called when something attempts to mark this database dirty.
 void handleDatabaseGetInfo()
          This is called when the user double-clicks or selects "Get Info" on this database.
 

Method Detail

handleDatabaseDirtied

public boolean handleDatabaseDirtied()
This is called when something attempts to mark this database dirty. The connection should make a determination whether it makes sense to mark the database as dirty, and it should return true or false depending on whether it is being dirtied or not.

Returns:
true if the database should be marked dirty

handleDatabaseGetInfo

public void handleDatabaseGetInfo()
This is called when the user double-clicks or selects "Get Info" on this database. The connection should typically respond by opening a pane with a description of the database, such as its size, location, URI and other attributes.


handleDatabaseClosing

public boolean handleDatabaseClosing()
This method is called when the main gui wants to close this database. The connection may veto the close (for example, if the user cancels a save) by returning false. Returning true indicates to the main gui that it can remove the database from its list.

Returns:
true if the close was successful, or false if aborted.