1 | public class ColumnPriviligesTab extends BaseTableTab↵ | | 1 | public class TablePriviligesTab extends BaseTableTab↵
|
2 | {↵ | | 2 | {↵
|
| | | 3 | ↵
|
3 | /** Internationalized strings for this class. */↵ | | 4 | /** Internationalized strings for this class. */↵
|
4 | private static final StringManager s_stringMgr =↵ | | 5 | private static final StringManager s_stringMgr =↵
|
5 | StringManagerFactory.getStringManager(ColumnPriviligesTab.class); ↵ | | 6 | StringManagerFactory.getStringManager(TablePriviligesTab.class);↵
|
6 | ↵ | | 7 | ↵
|
7 | private int[] columnIndices = new int[] { 4, 6, 7, 5, 8 };↵ | | 8 | private int[] columnIndices = new int[] { 5, 6, 7, 4 };↵
|
8 | ↵ | | 9 | ↵
|
9 | /**↵ | | 10 | /**↵
|
10 | * Return the title for the tab.↵ | | 11 | * Return the title for the tab.↵
|
11 | *↵ | | 12 | *↵
|
12 | * @return The title for the tab.↵ | | 13 | * @return The title for the tab.↵
|
13 | */↵ | | 14 | */↵
|
14 | public String getTitle()↵ | | 15 | public String getTitle()↵
|
15 | {↵ | | 16 | {↵
|
16 | //i18n[ColumnPriviligesTab.title=Column Privileges]↵ | | 17 | //i18n[TablePriviligesTab.title=Privileges]↵
|
17 | return s_stringMgr.getString("ColumnPriviligesTab.title");↵ | | 18 | return s_stringMgr.getString("TablePriviligesTab.title");↵
|
18 | }↵ | | 19 | }↵
|
|
19 | /**↵ | | 20 | /**↵
|
20 | * Return the hint for the tab.↵ | | 21 | * Return the hint for the tab.↵
|
21 | *↵ | | 22 | *↵
|
22 | * @return The hint for the tab.↵ | | 23 | * @return The hint for the tab.↵
|
23 | */↵ | | 24 | */↵
|
24 | public String getHint()↵ | | 25 | public String getHint()↵
|
25 | {↵ | | 26 | {↵
|
26 | //i18n[ColumnPriviligesTab.hint=Show access rights for columns in the selected table] ↵ | | 27 | //i18n[TablePriviligesTab.hint=Show access rights for the selected table]↵
|
27 | return s_stringMgr.getString("ColumnPriviligesTab.hint");↵ | | 28 | return s_stringMgr.getString("TablePriviligesTab.hint");↵
|
28 | }↵ | | 29 | }↵
|
|
29 | /**↵ | | 30 | /**↵
|
30 | * Create the <TT>IDataSet</TT> to be displayed in this tab.↵ | | 31 | * Create the <TT>IDataSet</TT> to be displayed in this tab.↵
|
31 | */↵ | | 32 | */↵
|
32 | protected IDataSet createDataSet() throws DataSetException↵ | | 33 | protected IDataSet createDataSet() throws DataSetException↵
|
33 | {↵ | | 34 | {↵
|
34 | final SQLDatabaseMetaData md = ↵ | | 35 | final SQLDatabaseMetaData md = ↵
|
35 | getSession().getSQLConnection().getSQLMetaData();↵ | | 36 | getSession().getSQLConnection().getSQLMetaData();↵
|
36 | final ITableInfo ti = getTableInfo();↵ | | 37 | ITableInfo ti = getTableInfo();↵
|
37 | return md.getColumnPrivilegesDataSet(ti,columnIndices, true) | | 38 | return md.getTablePrivilegesDataSet(ti, columnIndices, true)
|