|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjavax.swing.table.AbstractTableModel
edu.northwestern.at.wordhoard.swing.accounts.groups.GroupModel
public class GroupModel
Group model.
Each
group panel has a model which acts as a Swing table model,
manages all communications with the server session, and
maintains the following state information for the panel:
Window components register
listeners on the model to listen for and react appropriately to changes
in the state of the window.
| Field Summary |
|---|
| Fields inherited from class javax.swing.table.AbstractTableModel |
|---|
listenerList |
| Constructor Summary | |
|---|---|
GroupModel(WordHoardSession session,
AbstractWindow parentWindow)
Creates a new userGroup model. |
|
| Method Summary | |
|---|---|
(package private) void |
addListener(GroupListener listener)
Adds a listener. |
(package private) void |
createGroup()
Creates a new userGroup. |
(package private) void |
deleteGroups()
Deletes the selected groups. |
(package private) void |
err(java.lang.Exception e)
Handles an exception. |
int |
getColumnCount()
Gets the number of columns. |
java.lang.String |
getColumnName(int col)
Gets the name of a column. |
(package private) boolean |
getCreatingNewGroup()
Returns true if we are creating a new userGroup. |
int |
getRowCount()
Gets the number of rows. |
(package private) UserGroup |
getSelectedGroup()
Gets the currently selected userGroup. |
(package private) int[] |
getSelection()
Gets the selection. |
java.lang.Object |
getValueAt(int row,
int col)
Gets the value of a cell. |
void |
init()
Initializes the model. |
(package private) void |
removeListener(GroupListener listener)
Removes a listener. |
(package private) void |
save(java.lang.String name,
java.lang.String owner)
Saves a userGroup. |
void |
selectGroup(int index)
Requests that an userGroup be selected. |
(package private) void |
setSelection(int[] selection)
Sets the selection. |
| Methods inherited from class javax.swing.table.AbstractTableModel |
|---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, isCellEditable, removeTableModelListener, setValueAt |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GroupModel(WordHoardSession session,
AbstractWindow parentWindow)
throws java.lang.Exception
session - Server session.parentWindow - Parent window.
java.lang.Exception | Method Detail |
|---|
public int getRowCount()
public int getColumnCount()
public java.lang.Object getValueAt(int row,
int col)
row - Row index.col - Column index.
public java.lang.String getColumnName(int col)
getColumnName in interface javax.swing.table.TableModelgetColumnName in class javax.swing.table.AbstractTableModelcol - Column index.
public void init()
int[] getSelection()
void setSelection(int[] selection)
selection - Array of indexes of selected groups. UserGroup getSelectedGroup()
void save(java.lang.String name,
java.lang.String owner)
throws java.lang.Exception
name - Name.owner - User name for owner
java.lang.Exception public void selectGroup(int index)
index - Index of userGroup to be selected. void createGroup()
boolean getCreatingNewGroup()
void deleteGroups()
throws java.lang.Exception
java.lang.Exception void addListener(GroupListener listener)
listener - Group listener. void removeListener(GroupListener listener)
listener - Group listener. void err(java.lang.Exception e)
e - Exception.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||