1 package com.quantum.view.tableview;
3 import java.sql.SQLException;
5 import com.quantum.Messages;
6 import com.quantum.sql.SQLResultSetResults;
8 import org.eclipse.jface.viewers.ISelectionProvider;
9 import org.eclipse.ui.IViewPart;
15 public class ChangeEncodingAction extends ResultSetAction {
17 private final String encoding;
21 * @param selectionProvider
23 public ChangeEncodingAction(IViewPart view, ISelectionProvider selectionProvider, String encoding, String key) {
24 super(view, selectionProvider);
25 this.encoding = encoding;
26 setText(key + " " + Messages.getString(getClass(), "encoding"));
27 setToolTipText(key + " " + Messages.getString(getClass(), "encoding"));
31 * @see com.quantum.view.tableview.ResultSetAction#executeResultSetAction(com.quantum.sql.SQLResultSetResults)
33 protected void executeResultSetAction(SQLResultSetResults results)
35 results.setEncoding(this.encoding);
36 results.refresh(getConnection(results));