org.apache.myfaces.custom.tree.renderkit.html

Class HtmlTreeRenderer

public class HtmlTreeRenderer extends HtmlTableRendererBase

Version: $Revision: 239380 $ $Date: 2005-08-23 11:11:59 +0200 (Tue, 23 Aug 2005) $

Author: Oliver Rossmueller

Method Summary
voidencodeBegin(FacesContext facesContext, UIComponent uiComponent)
voidencodeChildren(FacesContext facesContext, UIComponent component)
voidencodeEnd(FacesContext facesContext, UIComponent component)
protected StringgetLayoutImage(HtmlTree tree, int state)
booleangetRendersChildren()
protected voidrenderChildren(FacesContext facesContext, ResponseWriter writer, HtmlTree tree, List children, int maxLevel, IconProvider iconProvider, UIComponent component)

Renders the children.

protected voidrenderChildren(FacesContext facesContext, ResponseWriter writer, HtmlTree tree, List children, int maxLevel, IconProvider iconProvider, int rowClassIndex, UIComponent component)

Renders the children given the rowClassIndex.

protected voidrenderColumnFooterRow(FacesContext facesContext, ResponseWriter writer, UIComponent component, String footerStyleClass, int maxLevel)
protected voidrenderColumnHeaderRow(FacesContext facesContext, ResponseWriter writer, UIComponent component, String headerStyleClass, int maxLevel)
protected voidrenderFacet(FacesContext facesContext, ResponseWriter writer, UIComponent component, boolean header, int maxLevel)

Overrides super renderFacet to render the HtmlTree facets.

protected voidrenderTreeColumnChild(FacesContext facesContext, ResponseWriter writer, UIComponent component, HtmlTree tree, HtmlTreeNode child, int maxLevel, IconProvider iconProvider)

Render the column where the tree is displayed.

Method Detail

encodeBegin

public void encodeBegin(FacesContext facesContext, UIComponent uiComponent)

encodeChildren

public void encodeChildren(FacesContext facesContext, UIComponent component)

encodeEnd

public void encodeEnd(FacesContext facesContext, UIComponent component)

getLayoutImage

protected String getLayoutImage(HtmlTree tree, int state)

getRendersChildren

public boolean getRendersChildren()

renderChildren

protected void renderChildren(FacesContext facesContext, ResponseWriter writer, HtmlTree tree, List children, int maxLevel, IconProvider iconProvider, UIComponent component)

Renders the children.

Parameters: facesContext The facesContext. writer The writer. tree The tree component. children The children to render. maxLevel The maximum level. iconProvider The icon provider.

Throws: IOException Throws an IOException.

renderChildren

protected void renderChildren(FacesContext facesContext, ResponseWriter writer, HtmlTree tree, List children, int maxLevel, IconProvider iconProvider, int rowClassIndex, UIComponent component)

Renders the children given the rowClassIndex.

Parameters: facesContext The facesContext. writer The writer. tree The tree component. children The children to render. maxLevel The maximum level. iconProvider The icon provider. rowClassIndex The row class index.

Throws: IOException Throws an IOException.

renderColumnFooterRow

protected void renderColumnFooterRow(FacesContext facesContext, ResponseWriter writer, UIComponent component, String footerStyleClass, int maxLevel)

renderColumnHeaderRow

protected void renderColumnHeaderRow(FacesContext facesContext, ResponseWriter writer, UIComponent component, String headerStyleClass, int maxLevel)

renderFacet

protected void renderFacet(FacesContext facesContext, ResponseWriter writer, UIComponent component, boolean header, int maxLevel)

Overrides super renderFacet to render the HtmlTree facets.

Parameters: facesContext The facesContext writer The writer. component The component. header Whether there is a header. maxLevel The max level for the rendered tree.

Throws: IOException Throws IOException.

renderTreeColumnChild

protected void renderTreeColumnChild(FacesContext facesContext, ResponseWriter writer, UIComponent component, HtmlTree tree, HtmlTreeNode child, int maxLevel, IconProvider iconProvider)

Render the column where the tree is displayed.

Parameters: facesContext The facesContext. writer The writer. component The component that will contain the tree. Null for default tree or HtmlTreeColumnfor table rendering. tree The tree, child The tree node child. maxLevel The max number of levels. iconProvider The iconProvider.

Throws: IOException Throws IOException.