Package org.apache.el

Class ExpressionFactoryImpl

    • Constructor Detail

      • ExpressionFactoryImpl

        public ExpressionFactoryImpl()
        Creates a new ExpressionFactoryImpl instance.
    • Method Detail

      • coerceToType

        public <T> T coerceToType​(java.lang.Object obj,
                                  java.lang.Class<T> type)
        Description copied from class: jakarta.el.ExpressionFactory
        Coerce the supplied object to the requested type.
        Specified by:
        coerceToType in class ExpressionFactory
        Type Parameters:
        T - The type to which the object should be coerced
        Parameters:
        obj - The object to be coerced
        type - The type to which the object should be coerced
        Returns:
        An instance of the requested type.
      • createMethodExpression

        public MethodExpression createMethodExpression​(ELContext context,
                                                       java.lang.String expression,
                                                       java.lang.Class<?> expectedReturnType,
                                                       java.lang.Class<?>[] expectedParamTypes)
        Description copied from class: jakarta.el.ExpressionFactory
        Create a new method expression instance.
        Specified by:
        createMethodExpression in class ExpressionFactory
        Parameters:
        context - The EL context for this evaluation
        expression - The String representation of the method expression
        expectedReturnType - The expected type of the result of invoking the method
        expectedParamTypes - The expected types of the input parameters
        Returns:
        A new method expression formed from the input parameters.
      • createValueExpression

        public ValueExpression createValueExpression​(ELContext context,
                                                     java.lang.String expression,
                                                     java.lang.Class<?> expectedType)
        Description copied from class: jakarta.el.ExpressionFactory
        Create a new value expression.
        Specified by:
        createValueExpression in class ExpressionFactory
        Parameters:
        context - The EL context for this evaluation
        expression - The String representation of the value expression
        expectedType - The expected type of the result of evaluating the expression
        Returns:
        A new value expression formed from the input parameters
      • createValueExpression

        public ValueExpression createValueExpression​(java.lang.Object instance,
                                                     java.lang.Class<?> expectedType)
        Description copied from class: jakarta.el.ExpressionFactory
        Creates a ValueExpression that, when evaluated, returns the given instance of the specified type. This is a convenience method for creating a constant value expression without requiring an ELContext.
        Specified by:
        createValueExpression in class ExpressionFactory
        Parameters:
        instance - the constant value to wrap
        expectedType - the expected type of the value
        Returns:
        a ValueExpression that returns the given instance when evaluated
      • getStreamELResolver

        public ELResolver getStreamELResolver()
        Description copied from class: jakarta.el.ExpressionFactory
        Returns an ELResolver capable of resolving properties on InputStream objects, enabling EL expressions to operate on stream types. This allows expressions to read data from input streams using standard property navigation syntax.
        Overrides:
        getStreamELResolver in class ExpressionFactory
        Returns:
        the StreamELResolver, or null if not supported by this implementation