Index

Class org.hsqldb.util.ZaurusEditor

org.hsqldb.util.ZaurusEditor

public class ZaurusEditor
ZaurusEditor implements an search/input/edit form to search/view/update/insert table records.


Constructor Index

 o ZaurusEditor()
Constructor declaration

Method Index

 o actionPerformed(ActionEvent)
actionPerformed method is the main entry point which interprets the buttons and initiates the actions.
 o clearStatus()
The class method clearStatus deletes the status line.
 o printStatus(String)
printStatus prints a text into the status line below the panel.
 o refresh(Connection)
refresh will read again the meta data of the actual database.

Constructors

 o ZaurusEditor
 public ZaurusEditor()
Constructor declaration

Methods

 o printStatus
 public static void printStatus(String text)
printStatus prints a text into the status line below the panel.

Parameters:
text - a String value will be shown
 o clearStatus
 public static void clearStatus()
The class method clearStatus deletes the status line.

 o actionPerformed
 public void actionPerformed(ActionEvent e)
actionPerformed method is the main entry point which interprets the buttons and initiates the actions.

Parameters:
e - an ActionEvent value is been sent to ZaurusEditor as ActionListener

The possible events are:

  • Buttons on the search panel:
    Search Row
    Starts the search of rows in the choosen table with the given search words and search options. Without any search words, all rows will be found.
    If no row meets the criteria, there will be a message in the status line.
    New Row
    An empty input panel for the choosen table is given. Any search words are ignored.
  • Buttons on the edit panel:
    Any changes to field values on this panel will be updated to the table when the actual row is left, i. e. when pressing one of the buttons 'Prev', 'Next' or 'Search'.
    Cancel
    Any changes to field contents are canceled and reset to the previous values.
    Prev
    Show the previous row which meets the search criteria.
    Next
    Show the next row which meets the search criteria.
    Delete
    This button has to be clicked twice and the shown row will be deleted from the table
    Search
    With this button a new search is initiated. Any changes made to field contents are saved
  • Buttons on the insert panel:
    Cancel Insert
    After beginning to fill a new row, the insert may be cancelled. The search panel will be shown next.
    New Insert
    The new row is inserted into the table and a new empty insert panel is shown.
    New Search
    The new row is inserted into the table and the search panel is shown again.
 o refresh
 public void refresh(Connection c)
refresh will read again the meta data of the actual database. This is useful after changes of the table structures for instance creating or dropping tables, or altering tabel. The method will be called if one asks to refresh the tree or if the connection to the database is changed.

Parameters:
c - a Connection is the actual connection to the database

Index