org.apache.beehive.netui.tags.databinding.datagrid
Class Header

Object
  extended by SimpleTagSupport
      extended by AbstractSimpleTag
          extended by AbstractDataGridHtmlTag
              extended by Header
All Implemented Interfaces:
JspTag, SimpleTag, IHtmlEvents, IHtmlI18n, INetuiTag

public class Header
extends AbstractDataGridHtmlTag
implements IHtmlEvents, IHtmlI18n

The Header tag is used to render a table row(s) before the data grid has rendered data rows as demarcated by the Rows tag. The header can also optionally render a <thead> HTML tag if the data grid is rendering HTML table row groups. To enable this functionality, set the DataGrid.setRenderRowGroups(boolean) attribute. The location of this tag inside of a data grid does not affect when its content renders. Table cells containing header describing columns of data along with sort and filter state / UI is commonly placed inside of a data grid's header.

The attribute setters for the footer tag are used to add HTML attributes to the ≶thead> HTML tag. When row group rendering is disabled, attributes set here do not render.

Because this tag renders inside of an HTML table, it by default renders an HTML <tr> tag to represent a table row. Table row tag rendering can be disabled using the setRenderRow(boolean) attribute. When this is disabled, the page author is responsible for maintaining the integrity of the HTML table by writing <tr> tags manually or by using the Row tag. When this tag is rendering it does not produce table cells; the contents of the table row in the footer is entirely left to the page author. With row rendering disabled, it is also possible to add multiple table rows to the end of a data grid.

The set of JSP implicit objects available to the body include:


Constructor Summary
Header()
           
 
Method Summary
 void doTag()
          Render this tag.
 String getTagName()
          The name of this tag; this value is used for error reporting.
 void setAlign(String align)
          Sets the value of the horizontal align attribute rendered by the HTML thead tag.
 void setChar(String alignChar)
          Sets the value of the horizontal alignment character attribute rendered by the HTML thead tag.
 void setCharoff(String alignCharOff)
          Sets the value of the horizontal alignment character offset attribute rendered by the HTML thead tag.
 void setDir(String dir)
          Sets the value of the text direction attribute rendered by the HTML thead tag.
 void setLang(String lang)
          Sets the value of the language attribute rendered by the HTML thead tag
 void setOnClick(String onClick)
          Sets the onClick JavaScript event for the HTML thead tag.
 void setOnDblClick(String onDblClick)
          Sets the onDblClick JavaScript event for the HTML thead tag.
 void setOnKeyDown(String onKeyDown)
          Sets the onKeyDown JavaScript event for the HTML thead tag.
 void setOnKeyPress(String onKeyPress)
          Sets the onKeyPress JavaScript event for the HTML thead tag.
 void setOnKeyUp(String onKeyUp)
          Sets the onKeyUp JavaScript event for the HTML thead tag.
 void setOnMouseDown(String onMouseDown)
          Sets the onMouseDown JavaScript event for the HTML thead tag.
 void setOnMouseMove(String onMouseMove)
          Sets the onMouseMove JavaScript event for the HTML thead tag.
 void setOnMouseOut(String onMouseOut)
          Sets the onMouseOut JavaScript event for the HTML thead tag.
 void setOnMouseOver(String onMouseOver)
          Sets the onMouseOver JavaScript event for the HTML thead tag.
 void setOnMouseUp(String onMouseUp)
          Sets the onMouseUp JavaScript event for the HTML thead tag.
 void setRenderRow(boolean renderRow)
          Set a boolean that enables / disables rendering HTML table rows by this tag.
 void setStyle(String style)
          Sets the style rendered by the HTML thead tag.
 void setStyleClass(String styleClass)
          Sets the style class of the rendered by the HTML thead tag.
 void setTagId(String tagId)
          Set the name of the tagId for the HTML thead tag.
 void setTitle(String title)
          Sets the value of the title attribute rendered by the HTML thead tag.
 void setValign(String valign)
          Sets the value of the vertical alignment attribute rendered by the HTML thead tag.
 
Methods inherited from class AbstractDataGridHtmlTag
applyIndexedTagId, applyTagId, lookupDataGridTagModel, renderDefaultNameAndId, renderNameAndId
 
Methods inherited from class AbstractSimpleTag
getBufferBody, getHtmlTag, getIdForTagId, getInlineError, getPageContext, getScriptReporter, getUserLocale, hasErrors, registerTagError, registerTagError, reportErrors, rewriteName, setNonEmptyValueAttribute, setRequiredValueAttribute, write
 
Methods inherited from class SimpleTagSupport
findAncestorWithClass, getJspBody, getJspContext, getParent, setJspBody, setJspContext, setParent
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Header

public Header()
Method Detail

getTagName

public String getTagName()
The name of this tag; this value is used for error reporting.

Specified by:
getTagName in interface INetuiTag
Specified by:
getTagName in class AbstractSimpleTag
Returns:
the String name of this tag

setOnClick

public void setOnClick(String onClick)
Sets the onClick JavaScript event for the HTML thead tag.

Specified by:
setOnClick in interface IHtmlEvents
Parameters:
onClick - the onClick event.

setOnDblClick

public void setOnDblClick(String onDblClick)
Sets the onDblClick JavaScript event for the HTML thead tag.

Specified by:
setOnDblClick in interface IHtmlEvents
Parameters:
onDblClick - the onDblClick event.

setOnKeyDown

public void setOnKeyDown(String onKeyDown)
Sets the onKeyDown JavaScript event for the HTML thead tag.

Specified by:
setOnKeyDown in interface IHtmlEvents
Parameters:
onKeyDown - the onKeyDown event.

setOnKeyUp

public void setOnKeyUp(String onKeyUp)
Sets the onKeyUp JavaScript event for the HTML thead tag.

Specified by:
setOnKeyUp in interface IHtmlEvents
Parameters:
onKeyUp - the onKeyUp event.

setOnKeyPress

public void setOnKeyPress(String onKeyPress)
Sets the onKeyPress JavaScript event for the HTML thead tag.

Specified by:
setOnKeyPress in interface IHtmlEvents
Parameters:
onKeyPress - the onKeyPress event.

setOnMouseDown

public void setOnMouseDown(String onMouseDown)
Sets the onMouseDown JavaScript event for the HTML thead tag.

Specified by:
setOnMouseDown in interface IHtmlEvents
Parameters:
onMouseDown - the onMouseDown event.

setOnMouseUp

public void setOnMouseUp(String onMouseUp)
Sets the onMouseUp JavaScript event for the HTML thead tag.

Specified by:
setOnMouseUp in interface IHtmlEvents
Parameters:
onMouseUp - the onMouseUp event.

setOnMouseMove

public void setOnMouseMove(String onMouseMove)
Sets the onMouseMove JavaScript event for the HTML thead tag.

Specified by:
setOnMouseMove in interface IHtmlEvents
Parameters:
onMouseMove - the onMouseMove event.

setOnMouseOut

public void setOnMouseOut(String onMouseOut)
Sets the onMouseOut JavaScript event for the HTML thead tag.

Specified by:
setOnMouseOut in interface IHtmlEvents
Parameters:
onMouseOut - the onMouseOut event.

setOnMouseOver

public void setOnMouseOver(String onMouseOver)
Sets the onMouseOver JavaScript event for the HTML thead tag.

Specified by:
setOnMouseOver in interface IHtmlEvents
Parameters:
onMouseOver - the onMouseOver event.

setStyle

public void setStyle(String style)
Sets the style rendered by the HTML thead tag.

Parameters:
style - the style

setStyleClass

public void setStyleClass(String styleClass)
Sets the style class of the rendered by the HTML thead tag.

Parameters:
styleClass - the style class

setTitle

public void setTitle(String title)
Sets the value of the title attribute rendered by the HTML thead tag.

Parameters:
title - the title

setAlign

public void setAlign(String align)
Sets the value of the horizontal align attribute rendered by the HTML thead tag.

Parameters:
align - the alignment

setChar

public void setChar(String alignChar)
Sets the value of the horizontal alignment character attribute rendered by the HTML thead tag.

Parameters:
alignChar - the alignment character

setCharoff

public void setCharoff(String alignCharOff)
Sets the value of the horizontal alignment character offset attribute rendered by the HTML thead tag.

Parameters:
alignCharOff - the alignment character offset

setValign

public void setValign(String valign)
Sets the value of the vertical alignment attribute rendered by the HTML thead tag.

Parameters:
valign - the vertical alignment

setLang

public void setLang(String lang)
Sets the value of the language attribute rendered by the HTML thead tag

Specified by:
setLang in interface IHtmlI18n
Parameters:
lang - the language

setDir

public void setDir(String dir)
Sets the value of the text direction attribute rendered by the HTML thead tag.

Specified by:
setDir in interface IHtmlI18n
Parameters:
dir - the dir attribute

setRenderRow

public void setRenderRow(boolean renderRow)
Set a boolean that enables / disables rendering HTML table rows by this tag. If the value is enabled, an HTML <tr> will be rendered when this tag renders its body. If the value is disabled, no <tr> tags will be rendered and the page author is responsible for maintaining the integrity of the HTML table.


setTagId

public void setTagId(String tagId)
              throws JspException
Set the name of the tagId for the HTML thead tag.

Parameters:
tagId - the the name of the tagId for the thead tag.
Throws:
JspException

doTag

public void doTag()
           throws JspException,
                  IOException
Render this tag. This method renders during the data grid's DataGridTagModel.RENDER_STATE_HEADER state in order to add table rows to the beginning of a data grid's HTML table. If the data grid is rendering HTML row groups, this tag will output an HTML <thead> tag. Then, if this tag is rendering a table row, it will produce an HTML <tr> tag. Then the content of the body will be rendered. If table row rendering is disabled, the page author is responsible for rendering the appropriate HTML table row tags as this tag renders inside of the HTML table opened by the data grid.

Specified by:
doTag in interface SimpleTag
Overrides:
doTag in class SimpleTagSupport
Throws:
IOException
JspException - when the DataGridTagModel can not be found in the JspContext