Updated map file.
[phpeclipse.git] / archive / net.sourceforge.phpeclipse.quantum.sql / src / com / quantum / view / tableview / RefreshTableAction.java
1 package com.quantum.view.tableview;
2
3 import java.sql.SQLException;
4
5 import com.quantum.ImageStore;
6 import com.quantum.Messages;
7 import com.quantum.sql.SQLResultSetResults;
8
9 import org.eclipse.jface.viewers.ISelectionProvider;
10 import org.eclipse.ui.IViewPart;
11
12 /**
13  * Implements the "Refresh Table" action for the TableView view
14  * 
15  * @author root
16  */
17 public class RefreshTableAction extends ResultSetAction {
18         
19         /**
20          * @param view
21          * @param selectionProvider
22          */
23         public RefreshTableAction(IViewPart view, ISelectionProvider selectionProvider) {
24                 super(view, selectionProvider);
25                 setText(Messages.getString(getClass(), "text"));
26                 setImageDescriptor(ImageStore.getImageDescriptor(ImageStore.REFRESH));
27                 setToolTipText(Messages.getString(getClass(), "text"));
28         }
29
30         protected void executeResultSetAction(SQLResultSetResults results) throws SQLException {
31                 results.refresh(getConnection(results));
32         }
33 }