org.apache.strutsel.taglib.logic
Class ELMatchSupport
java.lang.Object
org.apache.strutsel.taglib.logic.ELMatchSupport
- class ELMatchSupport
- extends java.lang.Object
This class is used as a helper class for both the
org.apache.strutsel.taglib.logic.ELMatchTag
and
org.apache.strutsel.taglib.logic.ELNotMatchTag
classes. It's
condition
method encapsulates the common logic needed to
examine the location
attribute to determine how to do the
comparison.
Method Summary |
static boolean |
condition(boolean desired,
java.lang.String expr,
java.lang.String value,
java.lang.String location,
org.apache.struts.util.MessageResources messages,
javax.servlet.jsp.PageContext pageContext)
Performs a comparison of an expression and a value, with an optional
location specifier in the expression (start or end). |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ELMatchSupport
ELMatchSupport()
condition
public static boolean condition(boolean desired,
java.lang.String expr,
java.lang.String value,
java.lang.String location,
org.apache.struts.util.MessageResources messages,
javax.servlet.jsp.PageContext pageContext)
throws javax.servlet.jsp.JspException
- Performs a comparison of an expression and a value, with an optional
location specifier in the expression (start or end).
- Parameters:
desired
- Indication of whether the "truth" value of the comparison
is whether the expression and value are equal, or not equal.expr
- Expression to test against a value.value
- Value to test against an expression.location
- if set, is "start" or "end" to indicate to look at the
start or end of the expression for the value. If null, look anywhere in
the expression.messages
- MessageResources
object to reference for
error message text.pageContext
- used to save exception information, if needed.
- Returns:
- true if comparison result equals desired value, false
otherwise.
- Throws:
javax.servlet.jsp.JspException
Copyright ? 2000-2005 - The Apache Software Foundation