1 | public class IndexDefragAction extends SquirrelAction implements ISessionAction {↵ | | 1 | public class ShowStatisticsAction extends SquirrelAction implements ISessionAction {↵
|
|
2 | private static final long serialVersionUID = 1L;↵ | | 2 | private static final long serialVersionUID = 1L;↵
|
3 | ↵ | | 3 | ↵
|
4 | private ISession _session;↵ | | 4 | transient private ISession _session;↵
|
5 | private final MssqlPlugin _plugin;↵ | | 5 | transient private final MssqlPlugin _plugin;↵
|
6 | ↵ | | 6 | ↵
|
7 | private final ITableInfo _tableInfo;↵ | | 7 | private final ITableInfo _tableInfo;↵
|
8 | private final String _indexName;↵ | | 8 | private final String _indexName;↵
|
|
9 | public IndexDefragAction(IApplication app, Resources rsrc, MssqlPlugin plugin, ITableInfo tableInfo, String indexName) {↵ | | 9 | public ShowStatisticsAction(IApplication app, Resources rsrc, MssqlPlugin plugin, ITableInfo tableInfo, String indexName) {↵
|
10 | super(app, rsrc);↵ | | 10 | super(app, rsrc);↵
|
11 | /* the constructor above sets this from resources, but we'll override it with↵ | | 11 | /* the constructor above sets this from resources, but we'll override it with↵
|
12 | * the name of the index. */↵ | | 12 | * the name of the index. */↵
|
13 | putValue(javax.swing.Action.NAME,indexName);↵ | | 13 | putValue(javax.swing.Action.NAME,indexName);↵
|
14 | _plugin = plugin;↵ | | 14 | _plugin = plugin;↵
|
15 | _tableInfo = tableInfo;↵ | | 15 | _tableInfo = tableInfo;↵
|
16 | _indexName = indexName;↵ | | 16 | _indexName = indexName;↵
|
17 | }↵ | | 17 | }↵
|
|
18 | public void actionPerformed(ActionEvent evt) {↵ | | 18 | public void actionPerformed(ActionEvent evt) {↵
|
19 | if (_session != null)↵ | | 19 | if (_session != null)↵
|
20 | new IndexDefragCommand(_session, _plugin, _tableInfo, _indexName).execute();↵ | | 20 | new ShowStatisticsCommand(_session, _plugin, _tableInfo, _indexName).execute();↵
|
21 | }↵ | | 21 | }↵
|
|
22 | public void setSession(ISession session) {↵ | | 22 | public void setSession(ISession session) {↵
|
23 | _session = session | | 23 | _session = session
|