01: /*
02: * MyGWT Widget Library
03: * Copyright(c) 2007, MyGWT.
04: * licensing@mygwt.net
05: *
06: * http://mygwt.net/license
07: */
08: package net.mygwt.ui.client.widget.table;
09:
10: /**
11: * Defines common methods for Table based components.
12: */
13: public interface ITable {
14:
15: /**
16: * Returns the table's column model.
17: *
18: * @return the column model
19: */
20: TableColumnModel getColumnModel();
21:
22: /**
23: * Returns the column at the specified index.
24: *
25: * @param index the column index
26: * @return the column
27: */
28: TableColumn getColumn(int index);
29:
30: /**
31: * Returns the table's header.
32: *
33: * @return the table header
34: */
35: TableHeader getTableHeader();
36:
37: /**
38: * Sorts the table using the specified column index.
39: *
40: * @param index the column index
41: * @param direction the direction to sort (NONE, ASC, DESC)
42: */
43: void sort(int index, int direction);
44:
45: /**
46: * Returns the column context menu enabled state.
47: *
48: * @return <code>true</code> if enabled, <code>false</code> otherwise.
49: */
50: boolean getColumnContextMenu();
51:
52: }
|