FormattableColumn Class

com.bea.wlw.netui.tags.databinding.grid.column
FormattableColumn Class

public abstract class FormattableColumn

    extends GridColumn
    implements Formattable

The abstract base class of a GridColumn that can accept NetUI FormatTag tags. Formatter tags are used to provide a consistent appearance of data that is rendered in a cell in a GridColumn. The value of a data cell is formatted before it is rendered.

Related Topics

Formattable


Hierarchy
Object
  TagSupport
    BodyTagSupport
      AbstractBaseTag
        StructuredBaseTag
          GridComponent
            GridColumn
              FormattableColumn
All Implemented Interfaces

BodyTag, Formattable, IterationTag, Serializable, Tag
Direct Known Subclasses

ExpressionColumn, SortFilterColumn

Field Summary

   
Fields from  com.bea.wlw.netui.tags.databinding.base.StructuredBaseTag
EMPTY_STRING
 
Fields from  com.bea.wlw.netui.tags.AbstractBaseTag
ATTR_GENERAL, ATTR_GENERAL_EXPRESSION, ATTR_JAVASCRIPT, ATTR_STYLE, CLASS, ID, JAVASCRIPT_STATUS, NAME, NETUI_UNIQUE_CNT, ONCLICK, ONDBLCLICK, ONKEYDOWN, ONKEYPRESS, ONKEYUP, ONMOUSEDOWN, ONMOUSEMOVE, ONMOUSEOUT, ONMOUSEOVER, ONMOUSEUP, STYLE, TABINDEX
 
Fields from  javax.servlet.jsp.tagext.BodyTagSupport
bodyContent
 
Fields from  javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields from interface javax.servlet.jsp.tagext.BodyTag
EVAL_BODY_BUFFERED, EVAL_BODY_TAG
 
Fields from interface javax.servlet.jsp.tagext.IterationTag
EVAL_BODY_AGAIN
 
Fields from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 

Constructor Summary

FormattableColumn()

 

Method Summary

public void
addFormatter(FormatTag.Formatter formatter)
Add a FormatTag to this tag.
protected String
format(Object value)
Format the text of the column with all of the registered FormatTag tags.
protected void
localRelease()
Reset all of the fields of this tag.
protected int
renderStartTag(int gridState)
In order for a formatted column to pick-up the formatters, it should evaluate its body.
 
Methods from  com.bea.wlw.netui.tags.databinding.grid.column.GridColumn
getColumns, getStyleClassPrefix, getValidContainerType, prepare, renderCloseCellTag, renderDataCell, renderDataCellTag, renderEndTag, renderFooterCell, renderFooterCellTag, renderHeaderCell, renderHeaderCellTag, renderOpenCellTag, setStyleClassPrefix
 
Methods from  com.bea.wlw.netui.tags.databinding.grid.GridComponent
getCurrentRenderState, getGrid, getGridContext, getValidContainerType, localRelease, prepare
 
Methods from  com.bea.wlw.netui.tags.databinding.base.StructuredBaseTag
addContent, doEndTag, doStartTag, getContent, getCurrentRenderState, getValidContainerType, localRelease, prepare, renderEndTag, renderStartTag, verifyAttributes, verifyStructure
 
Methods from  com.bea.wlw.netui.tags.AbstractBaseTag
addTagIdMapping, evaluateAttributeToString, filter, filter, getJavaScriptUtils, getNearestForm, getScriptReporter, getTagName, getUserLocale, localRelease, registerTagError, release, renderAttribute, rewriteName, write
 
Methods from  javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doEndTag, doInitBody, doStartTag, getBodyContent, getPreviousOut, release, setBodyContent
 
Methods from  javax.servlet.jsp.tagext.TagSupport
doAfterBody, doEndTag, doStartTag, findAncestorWithClass, getId, getParent, getValue, getValues, release, removeValue, setId, setPageContext, setParent, setValue
 
Methods from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
   
Methods from interface javax.servlet.jsp.tagext.BodyTag
doInitBody, setBodyContent
 
Methods from interface com.bea.wlw.netui.tags.html.Formattable
addFormatter
 
Methods from interface javax.servlet.jsp.tagext.IterationTag
doAfterBody
 
Methods from interface javax.servlet.jsp.tagext.Tag
doEndTag, doStartTag, getParent, release, setPageContext, setParent
 

Constructor Detail

FormattableColumn

public FormattableColumn()
 

Method Detail

addFormatter(FormatTag.Formatter) Method

public void addFormatter(FormatTag.Formatter formatter)
Add a FormatTag to this tag. The Formatter tags are used to format the value that will be written into this Grid cell. A Formatter tag registers itself with this Formattable tag using this method.

Parameters

formatter
the Formatter object to add to the list of formatters

Related Topics

Formattable


format(Object) Method

protected String format(Object value)
Format the text of the column with all of the registered FormatTag tags. Each of the formatters is called in order, chaining the value from the previous formatter into the next.

Parameters

value
the object to format

Returns

the result of applying all of the Formatter tags to the value Object.

localRelease() Method

protected void localRelease()
Reset all of the fields of this tag.

Overrides
GridColumn.localRelease()

renderStartTag(int) Method

protected int renderStartTag(int gridState)
In order for a formatted column to pick-up the formatters, it should evaluate its body. Child tags can override this behavior as necessary but should always evaluate the body in order to have the formatters applied.
The body is evaluated as buffered so that garbage text that may be in the body of the tag is ignored.

Overrides
GridColumn.renderStartTag(int)

Parameters

gridState
the state of this column's Grid tag parent

Returns

EVAL_BODY_BUFFERED