Author: [EMAIL PROTECTED]
Date: Wed Oct 8 15:31:25 2008
New Revision: 2761
Added:
trunk/src/ca/sqlpower/architect/swingui/query/SQLQueryUIComponents.java
(contents, props changed)
- copied, changed from r2757,
/trunk/src/ca/sqlpower/architect/swingui/query/SQLQueryEntryPanel.java
Modified:
trunk/src/ca/sqlpower/architect/swingui/query/QueryDialog.java
Log:
changed the class name SQLQueryEntryPanel to SQLQueryUIComponents since it
doesn't extends the JPanel anymore, in class SQLQueryUIComponents,we
refactored all the components so that they can be accessed n parts and make
it more flexible.We created a static method createQueryPanel to return a
default JComponent Layout.The main reason tto change this is to make all
the components in this class accessible for other uses.
Modified: trunk/src/ca/sqlpower/architect/swingui/query/QueryDialog.java
==============================================================================
--- trunk/src/ca/sqlpower/architect/swingui/query/QueryDialog.java
(original)
+++ trunk/src/ca/sqlpower/architect/swingui/query/QueryDialog.java Wed Oct
8 15:31:25 2008
@@ -20,14 +20,11 @@
package ca.sqlpower.architect.swingui.query;
import java.awt.BorderLayout;
-import java.sql.ResultSet;
-import java.util.List;
+import javax.swing.JComponent;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JSplitPane;
-import javax.swing.JTabbedPane;
-import javax.swing.JTextArea;
import javax.swing.tree.TreeModel;
import org.apache.log4j.Logger;
@@ -35,10 +32,6 @@
import ca.sqlpower.architect.ArchitectException;
import ca.sqlpower.architect.swingui.ArchitectSwingSession;
import ca.sqlpower.architect.swingui.DBTree;
-import ca.sqlpower.swingui.table.ResultSetTableFactory;
-
-import com.jgoodies.forms.builder.DefaultFormBuilder;
-import com.jgoodies.forms.layout.FormLayout;
/**
* This is like DBVisualizer, only not. It'll be different, I promise,
trust me....
@@ -49,17 +42,8 @@
private final DBTree dbTree;
- private SQLQueryEntryPanel queryEntryPanel;
-
- private JTabbedPane tabPane;
-
- /**
- * Any results returned by SQL statement execution that does not
return a table
- * will be placed here.
- */
- private JTextArea logTextArea;
-
- private JTabbedPane tableTabPane;
+ private JComponent queryPanel;
+
/**
* Creates and displays the window for executing SQL queries.
@@ -74,65 +58,20 @@
TreeModel model = session.getSourceDatabases().getModel();
dbTree.setModel(model);
- queryEntryPanel = new SQLQueryEntryPanel(session, dbTree);
- queryEntryPanel.addExecuteAction(new ExecuteActionListener() {
-
- public void sqlQueryExecuted(List<ResultSet> resultSets,
List<Integer> rowsAffected) {
- tableTabPane.removeAll();
- for (ResultSet rs : resultSets) {
-
tableTabPane.add(Messages.getString("SQLQuery.result"),
createResultSetTablePanel(rs));
- }
-
- logTextArea.setText("");
- for (Integer i : rowsAffected) {
-
logTextArea.append(Messages.getString("SQLQuery.rowsAffected",
i.toString()));
- logTextArea.append("\n\n");
- }
- }
-
- });
-
- tabPane = new JTabbedPane();
- tableTabPane = new JTabbedPane();
- logTextArea = new JTextArea();
+ queryPanel = SQLQueryUIComponents.createQueryPanel(session,
dbTree);
buildUI(session);
}
private void buildUI(ArchitectSwingSession session) {
- JSplitPane queryPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
- queryPane.add(queryEntryPanel, JSplitPane.TOP);
-
- tabPane.add(Messages.getString("SQLQuery.log"), new
JScrollPane(logTextArea));
-
- tabPane.add(Messages.getString("SQLQuery.result"), tableTabPane);
- queryPane.add(tabPane, JSplitPane.BOTTOM);
JSplitPane treePane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
treePane.add(new JScrollPane(dbTree), JSplitPane.LEFT);
- treePane.add(queryPane, JSplitPane.RIGHT);
+ treePane.add(queryPanel, JSplitPane.RIGHT);
setLayout(new BorderLayout());
add(treePane, BorderLayout.CENTER);
- }
-
- /**
- * Creates a new JPanel that displays a table of the result set.
- */
- private JPanel createResultSetTablePanel(ResultSet rs) {
- JTextArea tableFilterTextArea = new JTextArea();
- FormLayout tableAreaLayout = new FormLayout("pref, 10dlu,
pref:grow", "pref, 10dlu, fill:min(pref;100dlu):grow");
- DefaultFormBuilder tableAreaBuilder = new
DefaultFormBuilder(tableAreaLayout);
- tableAreaBuilder.setDefaultDialogBorder();
- tableAreaBuilder.append(Messages.getString("SQLQuery.filter"));
- tableAreaBuilder.append(new JScrollPane(tableFilterTextArea));
- tableAreaBuilder.nextLine();
- tableAreaBuilder.nextLine();
- JScrollPane tableScrollPane = new
JScrollPane(ResultSetTableFactory.createResultSetJTableWithSearch(rs,
tableFilterTextArea.getDocument()));
- tableAreaBuilder.append(tableScrollPane, 3);
-
- return tableAreaBuilder.getPanel();
}
}
Copied:
trunk/src/ca/sqlpower/architect/swingui/query/SQLQueryUIComponents.java
(from r2757,
/trunk/src/ca/sqlpower/architect/swingui/query/SQLQueryEntryPanel.java)
==============================================================================
--- /trunk/src/ca/sqlpower/architect/swingui/query/SQLQueryEntryPanel.java
(original)
+++ trunk/src/ca/sqlpower/architect/swingui/query/SQLQueryUIComponents.java
Wed Oct 8 15:31:25 2008
@@ -53,6 +53,8 @@
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JSpinner;
+import javax.swing.JSplitPane;
+import javax.swing.JTabbedPane;
import javax.swing.JTextArea;
import javax.swing.JToggleButton;
import javax.swing.JToolBar;
@@ -83,6 +85,7 @@
import ca.sqlpower.swingui.SPSUtils;
import ca.sqlpower.swingui.SPSwingWorker;
import ca.sqlpower.swingui.SwingWorkerRegistry;
+import ca.sqlpower.swingui.table.ResultSetTableFactory;
import com.jgoodies.forms.builder.DefaultFormBuilder;
import com.jgoodies.forms.layout.FormLayout;
@@ -90,9 +93,9 @@
/**
* This JPanel contains a text area to enter SQL script into and execute
it.
*/
-public class SQLQueryEntryPanel extends JPanel {
+public class SQLQueryUIComponents {
- private static Logger logger =
Logger.getLogger(SQLQueryEntryPanel.class);
+ private static Logger logger =
Logger.getLogger(SQLQueryUIComponents.class);
/**
* The entry value in the input map that will map a key press to our
@@ -230,15 +233,15 @@
executeButton.setEnabled(conMap.get(e.getItem()).getCurrentStmt() == null);
}
}
-
+
/**
* This will execute the sql statement in the sql text area.
*/
private class ExecuteSQLWorker extends SPSwingWorker {
List<CachedRowSet> resultSets = new ArrayList<CachedRowSet>();
- List<Integer> rowsAffected = new ArrayList<Integer>();
-
+ List<Integer> rowsAffected = new ArrayList<Integer>();
+
public ExecuteSQLWorker(SwingWorkerRegistry registry) {
super(registry);
}
@@ -248,25 +251,28 @@
Throwable e = getDoStuffException();
if (e != null) {
if (e instanceof SQLException) {
- SPSUtils.showExceptionDialogNoReport(getParent(),
Messages.getString("SQLQuery.failedConnectingToDB"), e);
+
SPSUtils.showExceptionDialogNoReport(queryPanel.getParent(),
Messages.getString("SQLQuery.failedConnectingToDB"), e);
} else {
throw new RuntimeException(e);
}
}
-
- for (ExecuteActionListener listener : executeListeners) {
- List<ResultSet> newRSList = new ArrayList<ResultSet>();
+
+ tableTabPane.removeAll();
for (CachedRowSet rs : resultSets) {
- newRSList.add(rs.createShared());
- }
- listener.sqlQueryExecuted(newRSList, rowsAffected);
- }
+ ResultSet r = rs.createShared();
+
tableTabPane.add(Messages.getString("SQLQuery.result"),
createResultSetTablePanel(r));
+ }
+ logTextArea.setText("");
+ for (Integer i : rowsAffected) {
+
logTextArea.append(Messages.getString("SQLQuery.rowsAffected",
i.toString()));
+ logTextArea.append("\n\n");
+ }
}
@Override
public void doStuff() throws Exception {
logger.debug("Starting execute action.");
- SPDataSource ds = (SPDataSource)databases.getSelectedItem();
+ SPDataSource ds =
(SPDataSource)databaseComboBox.getSelectedItem();
if (ds == null) {
return;
}
@@ -338,23 +344,7 @@
/**
* The action for executing and displaying a user's query.
*/
- private final AbstractAction executeAction = new
AbstractSQLQueryAction(this, Messages.getString("SQLQuery.execute")) {
-
- public void actionPerformed(ActionEvent e) {
- ConnectionAndStatementBean conBean =
conMap.get(databases.getSelectedItem());
- try {
- if(conBean!= null) {
- if (!conBean.getConnection().getAutoCommit()) {
- conBean.setConnectionUncommitted(true);
- }
- }
- } catch (SQLException e1) {
- SPSUtils.showExceptionDialogNoReport(parent,
Messages.getString("SQLQuery.failedRetrievingConnection",
((SPDataSource)databases.getSelectedItem()).getName()), e1);
- }
- sqlExecuteWorker = new ExecuteSQLWorker(session);
- new Thread(sqlExecuteWorker).start();
- }
- };
+ private final AbstractAction executeAction;
/**
* A mapping of data sources to live connections. These connections
will be left
@@ -374,7 +364,7 @@
* A combo box of available connections the user have specified. The
selected
* one will have the query run on it when the user hits the execute
button.
*/
- private final JComboBox databases;
+ private final JComboBox databaseComboBox;
private DropTarget dt;
@@ -399,6 +389,13 @@
*/
private final JButton rollbackButton;
+
+ private JButton undoButton;
+ private JButton redoButton;
+
+ private JTabbedPane tableTabPane;
+ private JTextArea logTextArea;
+
/**
* Listeners that will have it's sqlQueryExecuted method called when a
successful
* query is run.
@@ -439,15 +436,15 @@
private DatabaseListChangeListener dbListChangeListener = new
DatabaseListChangeListener() {
public void databaseAdded(DatabaseListChangeEvent e) {
- databases.addItem(e.getDataSource());
+ databaseComboBox.addItem(e.getDataSource());
}
public void databaseRemoved(DatabaseListChangeEvent e) {
- if (databases.getSelectedItem() != null &&
databases.getSelectedItem().equals(e.getDataSource())) {
- databases.setSelectedItem(null);
+ if (databaseComboBox.getSelectedItem() != null &&
databaseComboBox.getSelectedItem().equals(e.getDataSource())) {
+ databaseComboBox.setSelectedItem(null);
}
- databases.removeItem(e.getDataSource());
+ databaseComboBox.removeItem(e.getDataSource());
}
};
@@ -502,29 +499,65 @@
private JButton stopButton;
/**
+ * This button will clear the QueryTextField
+ */
+ private JButton clearButton;
+
+ /**
* Creates a SQLQueryEntryPanel and attaches a drag and drop listener
* to a DB Tree.
*/
- public SQLQueryEntryPanel(ArchitectSwingSession session, DBTree
dbTree) {
- this(session);
-
+
+ /**
+ * A JButton that opens up the DataBaseConnectionManager
+ */
+ private JButton dbcsManagerButton;
+
+ /**
+ * This is the panel that will hold all the JComponents
+ */
+ private JPanel queryPanel;
+
+ public SQLQueryUIComponents(ArchitectSwingSession session, DBTree
dbTree, JPanel panel) {
+ this(session, panel);
dt = new DropTarget(queryArea, new QueryDropListener(dbTree));
}
- public SQLQueryEntryPanel(ArchitectSwingSession s) {
+ public SQLQueryUIComponents(ArchitectSwingSession s, JPanel panel) {
super();
+ queryPanel = panel;
this.session = s;
+ tableTabPane = new JTabbedPane();
+ logTextArea = new JTextArea();
+
+ executeAction = new AbstractSQLQueryAction(queryPanel,
Messages.getString("SQLQuery.execute")) {
+
+ public void actionPerformed(ActionEvent e) {
+ ConnectionAndStatementBean conBean =
conMap.get(databaseComboBox.getSelectedItem());
+ try {
+ if(conBean!= null) {
+ if (!conBean.getConnection().getAutoCommit()) {
+ conBean.setConnectionUncommitted(true);
+ }
+ }
+ } catch (SQLException e1) {
+ SPSUtils.showExceptionDialogNoReport(parent,
Messages.getString("SQLQuery.failedRetrievingConnection",
((SPDataSource)databaseComboBox.getSelectedItem()).getName()), e1);
+ }
+ sqlExecuteWorker = new ExecuteSQLWorker(session);
+ new Thread(sqlExecuteWorker).start();
+ }
+ };
- autoCommitToggleButton = new JToggleButton(new
AbstractSQLQueryAction(this, Messages.getString("SQLQuery.autoCommit")) {
+ autoCommitToggleButton = new JToggleButton(new
AbstractSQLQueryAction(queryPanel,
Messages.getString("SQLQuery.autoCommit")) {
public void actionPerformed(ActionEvent e) {
- Connection con =
conMap.get(databases.getSelectedItem()).getConnection();
+ Connection con =
conMap.get(databaseComboBox.getSelectedItem()).getConnection();
if (con == null) {
return;
}
try {
boolean isPressed =
autoCommitToggleButton.getModel().isSelected();
- if (isPressed &&
conMap.get(databases.getSelectedItem()).isConnectionUncommitted()) {
+ if (isPressed &&
conMap.get(databaseComboBox.getSelectedItem()).isConnectionUncommitted()) {
int result = JOptionPane.showOptionDialog(parent,
Messages.getString("SQLQuery.commitOrRollbackBeforeAutoCommit"),
Messages.getString("SQLQuery.commitOrRollbackTitle"),
JOptionPane.YES_NO_CANCEL_OPTION, JOptionPane.QUESTION_MESSAGE, null,
new Object[]
{Messages.getString("SQLQuery.commit"),
Messages.getString("SQLQuery.cancel"),
Messages.getString("SQLQuery.rollback")},
Messages.getString("SQLQuery.commit"));
@@ -561,12 +594,12 @@
}
});
- commitButton = new JButton(new AbstractSQLQueryAction(this,
Messages.getString("SQLQuery.commit")) {
+ commitButton = new JButton(new AbstractSQLQueryAction(queryPanel,
Messages.getString("SQLQuery.commit")) {
public void actionPerformed(ActionEvent e) {
commitCurrentDB();
}});
- rollbackButton = new JButton(new AbstractSQLQueryAction(this,
Messages.getString("SQLQuery.rollback")){
+ rollbackButton = new JButton(new
AbstractSQLQueryAction(queryPanel, Messages.getString("SQLQuery.rollback")){
public void actionPerformed(ActionEvent e) {
rollbackCurrentDB();
}});
@@ -589,30 +622,22 @@
conMap = new HashMap<SPDataSource, ConnectionAndStatementBean>();
- databases = new
JComboBox(s.getContext().getConnections().toArray());
- databases.setSelectedItem(null);
- databases.addItemListener(new DatabaseItemListener(this));
+ databaseComboBox = new
JComboBox(s.getContext().getConnections().toArray());
+ databaseComboBox.setSelectedItem(null);
+ databaseComboBox.addItemListener(new
DatabaseItemListener(queryPanel));
- addAncestorListener(closeListener);
+ queryPanel.addAncestorListener(closeListener);
- getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).put(
+
queryPanel.getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).put(
KeyStroke.getKeyStroke(KeyEvent.VK_ENTER,
Toolkit.getDefaultToolkit().getMenuShortcutKeyMask())
, EXECUTE_QUERY_ACTION);
- getActionMap().put(EXECUTE_QUERY_ACTION, executeAction);
+ queryPanel.getActionMap().put(EXECUTE_QUERY_ACTION, executeAction);
- buildUI();
- }
-
- /**
- * Builds the UI of the [EMAIL PROTECTED] SQLQueryEntryPanel}.
- */
- private void buildUI() {
- JToolBar toolbar = new JToolBar();
executeButton = new JButton(executeAction);
- toolbar.add(executeButton);
- stopButton = new JButton(new AbstractSQLQueryAction(this,
Messages.getString("SQLQuery.stop")) {
+
+ stopButton = new JButton(new AbstractSQLQueryAction(queryPanel,
Messages.getString("SQLQuery.stop")) {
public void actionPerformed(ActionEvent arg0) {
- ConnectionAndStatementBean conBean =
conMap.get(databases.getSelectedItem());
+ ConnectionAndStatementBean conBean =
conMap.get(databaseComboBox.getSelectedItem());
if (conBean != null) {
Statement stmt = conBean.getCurrentStmt();
if (stmt != null) {
@@ -623,41 +648,69 @@
sqlExecuteWorker.kill();
}
} catch (SQLException e) {
- SPSUtils.showExceptionDialogNoReport(parent,
Messages.getString("SQLQuery.stopException",
((SPDataSource)databases.getSelectedItem()).getName()), e);
+ SPSUtils.showExceptionDialogNoReport(parent,
Messages.getString("SQLQuery.stopException",
((SPDataSource)databaseComboBox.getSelectedItem()).getName()), e);
}
}
}
}
- });
- toolbar.add(stopButton);
- toolbar.add(new AbstractSQLQueryAction(this,
Messages.getString("SQLQuery.clear")){
+ });
+ clearButton = new JButton(new AbstractSQLQueryAction(queryPanel,
Messages.getString("SQLQuery.clear")){
public void actionPerformed(ActionEvent arg0) {
queryArea.setText("");
}});
+
+ dbcsManagerButton = new JButton(new
DatabaseConnectionManagerAction(session));
+
dbcsManagerButton.setText(Messages.getString("SQLQuery.mangeConnections"));
+
+ undoButton= new JButton (undoSQLStatementAction);
+ redoButton= new JButton (redoSQLStatementAction);
+
+ }
+
+ /**
+ * Builds the UI of the [EMAIL PROTECTED] SQLQueryUIComponents}.
+ */
+ public static JComponent createQueryPanel(ArchitectSwingSession
session, DBTree dbTree) {
+
+ JPanel defaultQueryPanel = new JPanel();
+ SQLQueryUIComponents queryParts = new
SQLQueryUIComponents(session, dbTree, defaultQueryPanel);
+ JToolBar toolbar = new JToolBar();
+ toolbar.add(queryParts.getExecuteButton());
+ toolbar.add(queryParts.getStopButton());
+ toolbar.add(queryParts.getClearButton());
toolbar.addSeparator();
- toolbar.add(autoCommitToggleButton);
- toolbar.add(commitButton);
- toolbar.add(rollbackButton);
+ toolbar.add(queryParts.getAutoCommitToggleButton());
+ toolbar.add(queryParts.getCommitButton());
+ toolbar.add(queryParts.getRollbackButton());
toolbar.addSeparator();
- toolbar.add(undoSQLStatementAction);
- toolbar.add(redoSQLStatementAction);
+ toolbar.add(queryParts.getUndoButton());
+ toolbar.add(queryParts.getRedoButton());
FormLayout textAreaLayout = new FormLayout(
"pref:grow, 10dlu, pref, 10dlu, pref, 10dlu, pref"
, "pref, pref, fill:max(100dlu;pref):grow");
- DefaultFormBuilder textAreaBuilder = new
DefaultFormBuilder(textAreaLayout, this);
+ DefaultFormBuilder textAreaBuilder = new
DefaultFormBuilder(textAreaLayout, defaultQueryPanel);
textAreaBuilder.setDefaultDialogBorder();
textAreaBuilder.append(toolbar, 7);
textAreaBuilder.nextLine();
- textAreaBuilder.append(databases);
- JButton dbcsManagerButton = new JButton(new
DatabaseConnectionManagerAction(session));
-
dbcsManagerButton.setText(Messages.getString("SQLQuery.mangeConnections"));
- textAreaBuilder.append(dbcsManagerButton);
+ textAreaBuilder.append(queryParts.getDatabaseComboBox());
+ textAreaBuilder.append(queryParts.getDbcsManagerButton());
textAreaBuilder.append(Messages.getString("SQLQuery.rowLimit"));
- textAreaBuilder.append(rowLimitSpinner);
+ textAreaBuilder.append(queryParts.getRowLimitSpinner());
textAreaBuilder.nextLine();
- textAreaBuilder.append(new JScrollPane(queryArea), 7);
+ textAreaBuilder.append(new JScrollPane(queryParts.getQueryArea()),
7);
+
+
+ JSplitPane queryPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
+ JTabbedPane tabPane = new JTabbedPane();
+ queryPane.add(defaultQueryPanel, JSplitPane.TOP);
+ tabPane.add(Messages.getString("SQLQuery.log"), new
JScrollPane(queryParts.getLogTextArea()));
+
+ tabPane.add(Messages.getString("SQLQuery.result"),
queryParts.getTableTabPane());
+ queryPane.add(tabPane, JSplitPane.BOTTOM);
+
+ return queryPane;
}
@@ -674,7 +727,7 @@
* auto commit mode then any changes will be committed.
*/
private void commitCurrentDB() {
- ConnectionAndStatementBean conBean =
conMap.get(databases.getSelectedItem());
+ ConnectionAndStatementBean conBean =
conMap.get(databaseComboBox.getSelectedItem());
Connection con = conBean.getConnection();
if (con == null) {
return;
@@ -685,7 +738,7 @@
conBean.setConnectionUncommitted(false);
}
} catch (SQLException ex) {
- SPSUtils.showExceptionDialogNoReport(this,
Messages.getString("SQlQuery.failedCommit"), ex);
+ SPSUtils.showExceptionDialogNoReport(queryPanel,
Messages.getString("SQlQuery.failedCommit"), ex);
}
}
@@ -694,7 +747,7 @@
* auto commit mode then any changes will be rolled back.
*/
private void rollbackCurrentDB() {
- ConnectionAndStatementBean conBean =
conMap.get(databases.getSelectedItem());
+ ConnectionAndStatementBean conBean =
conMap.get(databaseComboBox.getSelectedItem());
Connection con = conBean.getConnection();
if (con == null) {
return;
@@ -705,8 +758,90 @@
conBean.setConnectionUncommitted(false);
}
} catch (SQLException ex) {
- SPSUtils.showExceptionDialogNoReport(this,
Messages.getString("SQLQuery.failedRollback"), ex);
+ SPSUtils.showExceptionDialogNoReport(queryPanel,
Messages.getString("SQLQuery.failedRollback"), ex);
}
}
+
+ /**
+ * Creates a new JPanel that displays a table of the result set.
+ */
+ private JPanel createResultSetTablePanel(ResultSet rs) {
+ JTextArea tableFilterTextArea = new JTextArea();
+ FormLayout tableAreaLayout = new FormLayout("pref, 10dlu,
pref:grow", "pref, 10dlu, fill:min(pref;100dlu):grow");
+ DefaultFormBuilder tableAreaBuilder = new
DefaultFormBuilder(tableAreaLayout);
+ tableAreaBuilder.setDefaultDialogBorder();
+ tableAreaBuilder.append(Messages.getString("SQLQuery.filter"));
+ tableAreaBuilder.append(new JScrollPane(tableFilterTextArea));
+ tableAreaBuilder.nextLine();
+ tableAreaBuilder.nextLine();
+ JScrollPane tableScrollPane = new
JScrollPane(ResultSetTableFactory.createResultSetJTableWithSearch(rs,
tableFilterTextArea.getDocument()));
+ tableAreaBuilder.append(tableScrollPane, 3);
+
+ return tableAreaBuilder.getPanel();
+ }
+
+
+ public JButton getExecuteButton() {
+ return executeButton;
+ }
+
+ public JButton getStopButton() {
+ return stopButton;
+ }
+
+ public JButton getClearButton() {
+ return clearButton;
+ }
+
+ public JToggleButton getAutoCommitToggleButton() {
+ return autoCommitToggleButton;
+ }
+
+ public JButton getCommitButton() {
+ return commitButton;
+ }
+
+ public JButton getRollbackButton() {
+ return rollbackButton;
+ }
+
+ public JButton getUndoButton() {
+ return undoButton;
+ }
+
+ public JButton getRedoButton() {
+ return redoButton;
+ }
+
+ public JComboBox getDatabaseComboBox() {
+ return databaseComboBox;
+ }
+
+ public JButton getDbcsManagerButton() {
+ return dbcsManagerButton;
+ }
+
+ public JSpinner getRowLimitSpinner() {
+ return rowLimitSpinner;
+ }
+
+ public JTextArea getQueryArea() {
+ return queryArea;
+ }
+
+ public JPanel getQueryPanel(){
+ return queryPanel;
+ }
+ public JTabbedPane getTableTabPane(){
+ return tableTabPane;
+ }
+ public JTextArea getLogTextArea(){
+ return logTextArea;
+ }
+
+
+
+
+
}