Class CAFValueExpression

java.lang.Object
javax.el.Expression
javax.el.ValueExpression
com.webmethods.caf.faces.application.CAFValueExpression
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
CAFMixedELValueExpression

public class CAFValueExpression extends ValueExpression
Wrap another value expression to allow different error handling
See Also:
  • Field Details

    • RE_BINDING

      protected static final Pattern RE_BINDING
    • shouldSuppressWarning

      protected boolean shouldSuppressWarning
    • wrappedValueBinding

      protected ValueExpression wrappedValueBinding
    • shouldSuppressWarningForThread

      protected static ThreadLocal<Boolean> shouldSuppressWarningForThread
  • Constructor Details

    • CAFValueExpression

      public CAFValueExpression()
      This should only be called when restoring state
    • CAFValueExpression

      public CAFValueExpression(Application application, ValueExpression wrappedValueBinding)
  • Method Details

    • getShouldSuppressWarningForThread

      public static Boolean getShouldSuppressWarningForThread()
      Returns whether to suppress the warnings for any expressions evaluated in the current thread
      Returns:
      true/false or null
    • setShouldSuppressWarningForThread

      public static void setShouldSuppressWarningForThread(Boolean shouldSuppressWarning)
      Sets whether to suppress the warnings for any expressions evaluated in the current thread. NOTE: if calling this, make sure to restore the original value when you are done.
      Parameters:
      shouldSuppressWarning - true/false or null
    • getShouldSuppressWarning

      public boolean getShouldSuppressWarning()
    • setShouldSuppressWarning

      public void setShouldSuppressWarning(boolean shouldSuppressWarning)
    • getExpressionsForDisplay

      protected String getExpressionsForDisplay()
      Gets just the binding expression bits for display in error message. If the expression string is really long, we don't want to display the whole dang thing.
    • getExpectedType

      public Class<?> getExpectedType()
      Specified by:
      getExpectedType in class ValueExpression
    • getType

      public Class<?> getType(ELContext elContext)
      Specified by:
      getType in class ValueExpression
    • getValue

      public Object getValue(ELContext elContext)
      Specified by:
      getValue in class ValueExpression
    • getCAFValue

      public Object getCAFValue(ELContext elContext)
    • isReadOnly

      public boolean isReadOnly(ELContext elContext)
      Specified by:
      isReadOnly in class ValueExpression
    • setValue

      public void setValue(ELContext elContext, Object value)
      Specified by:
      setValue in class ValueExpression
    • equals

      public boolean equals(Object thatObj)
      Specified by:
      equals in class Expression
    • getExpressionString

      public String getExpressionString()
      Specified by:
      getExpressionString in class Expression
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in class Expression
    • isLiteralText

      public boolean isLiteralText()
      Specified by:
      isLiteralText in class Expression
    • getValueReference

      public ValueReference getValueReference(ELContext context)
      Overrides:
      getValueReference in class ValueExpression