FileDocCategorySizeDatePackage
IfTag.javaAPI DocGlassfish v2 API4168Sat May 05 19:17:56 BST 2007org.apache.taglibs.standard.tag.el.core

IfTag

public class IfTag extends javax.servlet.jsp.jstl.core.ConditionalTagSupport

Tag handler for <if> in JSTL's expression-evaluating library. Because of the support provided by the ConditionalTagSupport class, thistag is trivial enough not to require a separate base supporting class common to both libraries.

author
Shawn Bayern

Fields Summary
private String
test
Constructors Summary
public IfTag()

        super();
        init();
    
Methods Summary
protected booleancondition()

	try {
            Object r = ExpressionEvaluatorManager.evaluate(
                "test", test, Boolean.class, this, pageContext);
            if (r == null)
                throw new NullAttributeException("if", "test");
	    else
	        return (((Boolean) r).booleanValue());
        } catch (JspException ex) {
	    throw new JspTagException(ex.toString(), ex);
	}
    
private voidinit()

        test = null;
    
public voidrelease()

        super.release();
        init();
    
public voidsetTest(java.lang.String test)

        this.test = test;