org.tentackle.ui
Class SumFormTableEntry

java.lang.Object
  extended by org.tentackle.ui.FormTableEntry
      extended by org.tentackle.ui.SumFormTableEntry

public class SumFormTableEntry
extends FormTableEntry

A formtable entry to sumup the numeric columns of a table.

Author:
harald

Constructor Summary
SumFormTableEntry()
          Creates an empty SumFormTableEntry.
SumFormTableEntry(AbstractFormTableModel model)
          Creates a SumFormTableEntry for a given table model.
 
Method Summary
 int getColumnCount()
          Determines the number of data-model columns.
 String getColumnName(int mColumn)
          Describes the column name.
This may be a symbolic name if getDisplayedColumnName() is overridden.
 Object getObject()
          Gets the object wrapped by this entry.
 Object getValueAt(int mColumn)
          Gets the column-object for this entry in a given column.
 FormTableEntry newInstanceOf(Object object)
          Creates a new instance of an entry for a given data-object.
 void sumUp(AbstractFormTableModel model)
          Sums up all numeric column in the model.
 
Methods inherited from class org.tentackle.ui.FormTableEntry
compareTo, fireCellsUpdated, fireRowUpdated, getCellEditor, getCellRect, getCellRenderer, getColumnClass, getConvert, getDisplayedColumnName, getFormat, getHorizontalAlignment, getModel, getReferencedColumn, getReferencedRow, getRow, getShowHorizontalLine, getShowVerticalLine, getVerticalAlignment, isAutoSelect, isBlankZero, isCellEditable, isCellEditorFixed, isCellRectFixed, isCellRendererFixed, isCellVisible, isColumnNotSummable, isVisiblyEqual, setModel, setRow, setValueAt, updateArray, updateCursor, updateList
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SumFormTableEntry

public SumFormTableEntry(AbstractFormTableModel model)
Creates a SumFormTableEntry for a given table model.

Parameters:
model - the form table model

SumFormTableEntry

public SumFormTableEntry()
Creates an empty SumFormTableEntry.

See Also:
sumUp(org.tentackle.ui.AbstractFormTableModel)
Method Detail

sumUp

public void sumUp(AbstractFormTableModel model)
Sums up all numeric column in the model.

Parameters:
model - the form table model

newInstanceOf

public FormTableEntry newInstanceOf(Object object)
Description copied from class: FormTableEntry
Creates a new instance of an entry for a given data-object.

Specified by:
newInstanceOf in class FormTableEntry
Parameters:
object - the data-object
Returns:
the FormTableEntry for this object

getValueAt

public Object getValueAt(int mColumn)
Description copied from class: FormTableEntry
Gets the column-object for this entry in a given column.

Specified by:
getValueAt in class FormTableEntry
Parameters:
mColumn - the datamodel-column
Returns:
the column data object

getColumnName

public String getColumnName(int mColumn)
Description copied from class: FormTableEntry
Describes the column name.
This may be a symbolic name if getDisplayedColumnName() is overridden.

Specified by:
getColumnName in class FormTableEntry
Parameters:
mColumn - the datamodel-column
Returns:
the name of the column

getObject

public Object getObject()
Description copied from class: FormTableEntry
Gets the object wrapped by this entry.

Specified by:
getObject in class FormTableEntry
Returns:
the data object

getColumnCount

public int getColumnCount()
Description copied from class: FormTableEntry
Determines the number of data-model columns. Notice that not all columns may actually be visible.

Specified by:
getColumnCount in class FormTableEntry
Returns:
the number of columns


Copyright © 2001-2008 Harald Krake, Bergstr. 48, 78098 Triberg, Germany, harald@krake.de