org.apache.struts2.components.table.renderer
Class NumericCellRenderer
java.lang.Object
org.apache.struts2.components.table.renderer.AbstractCellRenderer
org.apache.struts2.components.table.renderer.NumericCellRenderer
- All Implemented Interfaces:
- CellRenderer
public class NumericCellRenderer
- extends AbstractCellRenderer
Method Summary |
java.lang.String |
getCellValue(WebTable table,
java.lang.Object data,
int row,
int col)
this is the method that subclasses need to implement to set their value. |
protected void |
processNumber(java.lang.StringBuffer buf,
java.lang.String color,
double cellValue)
|
void |
setFormatString(java.lang.String format)
|
void |
setNegativeColor(java.lang.String color)
|
void |
setPositiveColor(java.lang.String color)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NumericCellRenderer
public NumericCellRenderer()
getCellValue
public java.lang.String getCellValue(WebTable table,
java.lang.Object data,
int row,
int col)
- Description copied from class:
AbstractCellRenderer
- this is the method that subclasses need to implement to set their value.
they should not override renderCell unless they want to change the alignmnent
renderering
- Specified by:
getCellValue
in class AbstractCellRenderer
setFormatString
public void setFormatString(java.lang.String format)
setNegativeColor
public void setNegativeColor(java.lang.String color)
setPositiveColor
public void setPositiveColor(java.lang.String color)
processNumber
protected void processNumber(java.lang.StringBuffer buf,
java.lang.String color,
double cellValue)
Copyright © 2000-2006 Apache Software Foundation. All Rights Reserved.