org.apache.strutsel.taglib.utils
Class EvalHelper

java.lang.Object
  extended by org.apache.strutsel.taglib.utils.EvalHelper

public final class EvalHelper
extends java.lang.Object

This class is used in the evaluateExpressions method of each Tag class. It is used to process the original attribute value through the JSTL EL engine to produce an evaluated value. It provides functions to evaluate the expression assuming it is an Object, String, Integer, or Boolean result.


Method Summary
static java.lang.Object eval(java.lang.String attrName, java.lang.String attrValue, javax.servlet.jsp.tagext.Tag tagObject, javax.servlet.jsp.PageContext pageContext)
          Evaluates the attribute value in the JSTL EL engine, returning the raw Object value of the evaluated expression.
static java.lang.Boolean evalBoolean(java.lang.String attrName, java.lang.String attrValue, javax.servlet.jsp.tagext.Tag tagObject, javax.servlet.jsp.PageContext pageContext)
          Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is an Boolean object.
static java.lang.Integer evalInteger(java.lang.String attrName, java.lang.String attrValue, javax.servlet.jsp.tagext.Tag tagObject, javax.servlet.jsp.PageContext pageContext)
          Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is an Integer object.
static java.lang.String evalString(java.lang.String attrName, java.lang.String attrValue, javax.servlet.jsp.tagext.Tag tagObject, javax.servlet.jsp.PageContext pageContext)
          Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is a String object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

eval

public static java.lang.Object eval(java.lang.String attrName,
                                    java.lang.String attrValue,
                                    javax.servlet.jsp.tagext.Tag tagObject,
                                    javax.servlet.jsp.PageContext pageContext)
                             throws javax.servlet.jsp.JspException
Evaluates the attribute value in the JSTL EL engine, returning the raw Object value of the evaluated expression. If the original expression is null, or the resulting value is null, it will return null.

Throws:
javax.servlet.jsp.JspException

evalString

public static java.lang.String evalString(java.lang.String attrName,
                                          java.lang.String attrValue,
                                          javax.servlet.jsp.tagext.Tag tagObject,
                                          javax.servlet.jsp.PageContext pageContext)
                                   throws javax.servlet.jsp.JspException
Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is a String object. If the original expression is null, or the resulting value is null, it will return null.

Throws:
javax.servlet.jsp.JspException

evalInteger

public static java.lang.Integer evalInteger(java.lang.String attrName,
                                            java.lang.String attrValue,
                                            javax.servlet.jsp.tagext.Tag tagObject,
                                            javax.servlet.jsp.PageContext pageContext)
                                     throws javax.servlet.jsp.JspException
Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is an Integer object. If the original expression is null, or the resulting value is null, it will return null.

Throws:
javax.servlet.jsp.JspException

evalBoolean

public static java.lang.Boolean evalBoolean(java.lang.String attrName,
                                            java.lang.String attrValue,
                                            javax.servlet.jsp.tagext.Tag tagObject,
                                            javax.servlet.jsp.PageContext pageContext)
                                     throws javax.servlet.jsp.JspException
Evaluates the attribute value in the JSTL EL engine, assuming the resulting value is an Boolean object. If the original expression is null, or the resulting value is null, it will return null.

Throws:
javax.servlet.jsp.JspException


Copyright © 2000-2010 Apache Software Foundation. All Rights Reserved.