|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.swing.table.AbstractTableModel | +--planetj.gui.CMTableModel | +--planetj.gui.CMSmartTableModel
CMSmartTableModel allows users to load a table with business objects or row objects per table row. It handles table selection handling and selection modes. This class provides functionality to retrieve the selected business objects or row objects from the table.
Constructor Summary | |
CMSmartTableModel()
CMSmartTableModel constructor comment. |
Method Summary | |
boolean |
getBusinessObjectsAreInvokable()
Gets the businessObjectsAreInvokable property (boolean) value. |
Class |
getColumnClass(int column)
Insert the method's description here. |
List |
getColumnGetterMethodObjects()
Gets the column getter methods via a List of Method objects. |
String[] |
getColumnGetterMethods()
Gets the columnGetterMethods property (java.lang.String[]) value. |
String |
getColumnGetterMethods(int index)
Gets the name of the getter method at the specified index |
Integer[] |
getColumnsContainingIcons()
Insert the method's description here. |
JTable |
getJTable()
Gets the jTable property (javax.swing.JTable) value. |
Object |
getSelectedBusinessObject()
Gets the selectedBusinessObject property (java.lang.Object) value. |
Object |
getSelectedBusinessObjectAsString()
Gets the selectedBusinessObject property (java.lang.Object) value as a String. |
List |
getSelectedBusinessObjects()
Gets the selected business objects |
int |
getSelectedRowIndex()
Gets the index of the selected row |
int |
getSelectionMode()
|
TableColumn |
getTableColumn(int index)
|
Object |
getValueAt(int row,
int col)
getValueAt method comment. |
boolean |
isCellEditable(int row,
int col)
Insert the method's description here. |
int |
selectNextBusinessObject()
Selects the next business object in the list and returns the index of the newly selected object. |
int |
selectPreviousBusinessObject()
Selects the next business object in the list and returns the index of the newly selected object. |
void |
setAllObjects(List allObjects)
Sets the allObjects property (java.util.Vector) value. |
void |
setBusinessObjectsAreInvokable(boolean businessObjectsAreInvokable)
Sets the businessObjectsAreInvokable property (boolean) value. |
void |
setColumnGetterMethodObjects(List pMethodObjects)
Sets the column getter methods via a List of Method objects. |
void |
setColumnGetterMethods(int index,
String columnGetterMethods)
Sets the column getter method at the specified index |
void |
setColumnGetterMethods(String[] columnGetterMethods)
Sets the array of getter method names. |
void |
setColumnsContainingIcons(Integer[] newColumnsContainingIcons)
Insert the method's description here. |
void |
setJTable(JTable jTable)
Sets the jTable property (javax.swing.JTable) value. |
void |
setSelectedBusinessObject(Object selectedBusinessObject)
Sets the selectedBusinessObject property (java.lang.Object) value. |
void |
setSelectedRowIndex(int rowIndex)
Sets the selected row to the specified index |
void |
setSelectionMode(int newSelectionMode)
Insert the method's description here. |
void |
setTableColumn(Object o)
|
void |
valueChanged(ListSelectionEvent e)
Called whenever the value of the selection changes. |
Methods inherited from class planetj.gui.CMTableModel |
addPropertyChangeListener, addPropertyChangeListener, firePropertyChange, getAllObjects, getBusinessObject, getColumnCount, getColumnName, getColumnNames, getRowCount, getTranslation, removePropertyChangeListener, removePropertyChangeListener, setColumnCount, setColumnName, setColumnNames |
Methods inherited from class javax.swing.table.AbstractTableModel |
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener, setValueAt |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CMSmartTableModel()
Method Detail |
public boolean getBusinessObjectsAreInvokable()
setBusinessObjectsAreInvokable(boolean)
public Class getColumnClass(int column)
getColumnClass
in interface TableModel
getColumnClass
in class AbstractTableModel
public List getColumnGetterMethodObjects()
public String[] getColumnGetterMethods()
setColumnGetterMethods(java.lang.String[])
public String getColumnGetterMethods(int index)
public Integer[] getColumnsContainingIcons()
public JTable getJTable()
setJTable(javax.swing.JTable)
public Object getSelectedBusinessObject()
setSelectedBusinessObject(java.lang.Object)
public Object getSelectedBusinessObjectAsString()
setSelectedBusinessObject(java.lang.Object)
public List getSelectedBusinessObjects()
public int getSelectedRowIndex()
public int getSelectionMode()
public TableColumn getTableColumn(int index)
public Object getValueAt(int row, int col)
getValueAt
in interface TableModel
getValueAt
in class CMTableModel
public boolean isCellEditable(int row, int col)
isCellEditable
in interface TableModel
isCellEditable
in class AbstractTableModel
row
- intcol
- int
public int selectNextBusinessObject()
public int selectPreviousBusinessObject()
public void setAllObjects(List allObjects)
setAllObjects
in class CMTableModel
allObjects
- The new value for the property.CMTableModel.getAllObjects()
public void setBusinessObjectsAreInvokable(boolean businessObjectsAreInvokable)
businessObjectsAreInvokable
- The new value for the property.getBusinessObjectsAreInvokable()
public void setColumnGetterMethodObjects(List pMethodObjects)
pMethodObjects
- A List containing Method objectspublic void setColumnGetterMethods(String[] columnGetterMethods)
public void setColumnGetterMethods(int index, String columnGetterMethods)
public void setColumnsContainingIcons(Integer[] newColumnsContainingIcons)
newColumnsContainingIcons
- Integer[]public void setJTable(JTable jTable)
jTable
- The new value for the property.getJTable()
public void setSelectedBusinessObject(Object selectedBusinessObject)
selectedBusinessObject
- The new value for the property.getSelectedBusinessObject()
public void setSelectedRowIndex(int rowIndex)
rowIndex
- intpublic void setSelectionMode(int newSelectionMode)
public void setTableColumn(Object o)
public void valueChanged(ListSelectionEvent e)
valueChanged
in interface ListSelectionListener
e
- the event that characterizes the change.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |