org.chwf.taglib.jutil
Class PrintErrorTag

java.lang.Object
  |
  +--javax.servlet.jsp.tagext.TagSupport
        |
        +--org.chwf.taglib.base.LifeCycleTagSupport
              |
              +--org.chwf.taglib.jutil.PrintErrorTag
All Implemented Interfaces:
Parameterized, java.io.Serializable, javax.servlet.jsp.tagext.Tag

public class PrintErrorTag
extends LifeCycleTagSupport

Tag handler for the <printError> tag. It checks for an exception object in the request and prints its message.

Author:
Paul Strack
See Also:
Serialized Form

Fields inherited from class javax.servlet.jsp.tagext.TagSupport
id, pageContext
 
Fields inherited from interface javax.servlet.jsp.tagext.Tag
EVAL_BODY_INCLUDE, EVAL_PAGE, SKIP_BODY, SKIP_PAGE
 
Constructor Summary
PrintErrorTag()
           
 
Method Summary
 void cleanup()
          Clean up data for tag handler reuse and pooling.
 int doStart()
          Prints the error message.
 java.lang.String getParameter()
          For parameter-associated errors.
 void setParameter(java.lang.String parameter)
          For parameter-associated errors.
 
Methods inherited from class org.chwf.taglib.base.LifeCycleTagSupport
addAttribute, addParameter, doEnd, doEndTag, doStartTag, getAttribute, getAttributeNames, getParameter, getParameterNames, init, printAttributes
 
Methods inherited from class javax.servlet.jsp.tagext.TagSupport
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
 

Constructor Detail

PrintErrorTag

public PrintErrorTag()
Method Detail

cleanup

public void cleanup()
Clean up data for tag handler reuse and pooling. Should be overridden in tag handler. Subclasses should always invoke their superclass's cleanup method: super.cleanup()
Overrides:
cleanup in class LifeCycleTagSupport

setParameter

public void setParameter(java.lang.String parameter)
For parameter-associated errors.
Parameters:
parameter - The parameter.

getParameter

public java.lang.String getParameter()
For parameter-associated errors.
Returns:
The parameter.

doStart

public int doStart()
            throws java.io.IOException
Prints the error message.
Overrides:
doStart in class LifeCycleTagSupport
Returns:
SKIP_BODY
Throws:
java.io.IOException - For IO exceptions.


Copyright © 2002-2004, Paul Strack. All Rights Reserved.