2.17.2: 2011-06-17

net.sf.basedb.clients.web.taglib.table
Class CellValue

java.lang.Object
  extended by javax.servlet.jsp.tagext.TagSupport
      extended by net.sf.basedb.clients.web.taglib.table.CellValue
All Implemented Interfaces:
Serializable, IterationTag, JspTag, Tag

public class CellValue
extends TagSupport

This tag adds a value to a cell in a row. It should be placed inside a <tbl:cell> tag.

Syntax:

   <tbl:cellvalue
      value=...
      list=...
      separator=...
      prefix=...
      suffix=...
   >

Attribute Default value Required Description
value - no A value to display in the cell. If a Formatter has been defined for this column the value is formatted otherwise it is just converted to a string with the toString() method.
list - no A list of values to display in the cell. Each value is formatted the same way as for a single value. If a single value is also specified it is printed first.
separator ; no A separator to use between each value in a list.
prefix no A prefix that is added before each value. Since 2.9.
suffix no A suffix that is added after each value. Since 2.9.

Version:
2.0
Author:
Nicklas
See Also:
Serialized Form

Field Summary
private  Iterable<?> list
           
private  String prefix
           
private  String separator
           
private static long serialVersionUID
           
private  String suffix
           
private static Formatter toStringFormatter
           
private  Object value
          The value to display.
 
Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
CellValue()
           
 
Method Summary
 int doStartTag()
           
 Iterable<?> getList()
           
 String getPrefix()
           
 String getSeparator()
           
 String getSuffix()
           
 Object getValue()
           
 void setList(Iterable<?> list)
           
 void setPrefix(String prefix)
           
 void setSeparator(String separator)
           
 void setSuffix(String suffix)
           
 void setValue(Object value)
           
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
doAfterBody, doEndTag, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

toStringFormatter

private static final Formatter toStringFormatter

value

private Object value
The value to display.


list

private Iterable<?> list

prefix

private String prefix

suffix

private String suffix

separator

private String separator
Constructor Detail

CellValue

public CellValue()
Method Detail

setValue

public void setValue(Object value)

getValue

public Object getValue()

setList

public void setList(Iterable<?> list)

getList

public Iterable<?> getList()

setSeparator

public void setSeparator(String separator)

getSeparator

public String getSeparator()

setPrefix

public void setPrefix(String prefix)
Since:
2.9

getPrefix

public String getPrefix()
Since:
2.9

setSuffix

public void setSuffix(String suffix)
Since:
2.9

getSuffix

public String getSuffix()
Since:
2.9

doStartTag

public int doStartTag()
               throws JspException
Specified by:
doStartTag in interface Tag
Overrides:
doStartTag in class TagSupport
Throws:
JspException

2.17.2: 2011-06-17