IncludeSection Class

com.bea.wlw.netui.tags.template
IncludeSection Class

public class IncludeSection

    extends AbstractBaseTag
    implements TemplateConstants

Used within a template JSP page to define a placeholder for section content. Within a template, one or more sections are defined within the overall structure of the page. Each section has a unique name identifying it. The content page, through the Section tag, provides content that is included into the defined sections.

All content found within the body of the IncludeSection is ignored.

Attribute Descriptions
AttributeRequiredRuntime Expression Evaluation Data Bindable
nameYesNoNo
The name of the section placeholder. The name must be unique within a template.
defaultPageNoNoNo
A URL identifying a default JSP or HTML page to provide content if the content page does not.

Related Topics

<netui-template:...> Tags Sample
Attribute
Section
SetAttribute
Template
Visible


Hierarchy
Object
  TagSupport
    BodyTagSupport
      AbstractBaseTag
        IncludeSection
All Implemented Interfaces

BodyTag, IterationTag, Serializable, Tag, TemplateConstants

Field Summary

   
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
 
Fields from interface com.bea.wlw.netui.tags.template.TemplateConstants
TEMPLATE_ATTRIBUTES, TEMPLATE_SECTIONS
 

Constructor Summary

IncludeSection()

 

Method Summary

public int
doStartTag()
Renders the content of the section into the template.
public String
getDefaultPage()
Returns the URL of the JSP or HTML page providing default content to the defined section.
public String
getName()
Returns the name of the defined section within the template file.
public String
getTagName()
Returns the name of the Tag.
protected void
localRelease()
Resets all of the fields of the tag.
public void
setDefaultPage(String defaultPage)
Sets a default JSP page to provide content for the section if the content page does not define the content.
public void
setName(String name)
Sets the name of the section.
 
Methods from  com.bea.wlw.netui.tags.AbstractBaseTag
addTagIdMapping, evaluateAttributeToString, filter, filter, getJavaScriptUtils, getNearestForm, getScriptReporter, getUserLocale, registerTagError, release, renderAttribute, rewriteName, write
 
Methods from  javax.servlet.jsp.tagext.BodyTagSupport
doAfterBody, doEndTag, doInitBody, 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 javax.servlet.jsp.tagext.IterationTag
doAfterBody
 
Methods from interface javax.servlet.jsp.tagext.Tag
doEndTag, doStartTag, getParent, release, setPageContext, setParent
 

Constructor Detail

IncludeSection

public IncludeSection()
 

Method Detail

doStartTag() Method

public int doStartTag()
throws JspException
Renders the content of the section into the template. Errors are reported inline within the template in development mode. If no sections are defined an error is reported. If a section is not defined and no default URL is provided an error is reported.

Overrides
BodyTagSupport.doStartTag()

Returns

SKIP_BODY to skip any content found in the tag.

Exceptions

JspException
on Errors.

getDefaultPage() Method

public String getDefaultPage()
Returns the URL of the JSP or HTML page providing default content to the defined section.

Returns

the URL of the default content.

getName() Method

public String getName()
Returns the name of the defined section within the template file.

Returns

the name of the IncludeSection being defined.

getTagName() Method

public String getTagName()
Returns the name of the Tag. This is used to identify the type of tag reporting errors.

Overrides
AbstractBaseTag.getTagName()

localRelease() Method

protected void localRelease()
Resets all of the fields of the tag.

Overrides
AbstractBaseTag.localRelease()

setDefaultPage(String) Method

public void setDefaultPage(String defaultPage)
Sets a default JSP page to provide content for the section if the content page does not define the content.

Parameters

defaultPage
a URL identifying a JSP or HTML page providing default content to the defined section.

setName(String) Method

public void setName(String name)
Sets the name of the section. This name must be unique within the template page.

Parameters

name
The name of the defined section within the template. This name must be unique within the template.