diff --git a/spring-expression/src/main/java/org/springframework/expression/spel/ast/FunctionReference.java b/spring-expression/src/main/java/org/springframework/expression/spel/ast/FunctionReference.java index d5641abdba..c6dfb2c9b3 100644 --- a/spring-expression/src/main/java/org/springframework/expression/spel/ast/FunctionReference.java +++ b/spring-expression/src/main/java/org/springframework/expression/spel/ast/FunctionReference.java @@ -37,13 +37,10 @@ import org.springframework.util.ReflectionUtils; /** * A function reference is of the form "#someFunction(a,b,c)". Functions may be defined - * in the context prior to the expression being evaluated or within the expression itself - * using a lambda function definition. For example: Lambda function definition in an - * expression: "(#max = {|x,y|$x>$y?$x:$y};max(2,3))" Calling context defined function: - * "#isEven(37)". Functions may also be static java methods, registered in the context - * prior to invocation of the expression. + * in the context prior to the expression being evaluated. Functions may also be static + * Java methods, registered in the context prior to invocation of the expression. * - *

Functions are very simplistic, the arguments are not part of the definition + *

Functions are very simplistic. The arguments are not part of the definition * (right now), so the names must be unique. * * @author Andy Clement @@ -73,7 +70,7 @@ public class FunctionReference extends SpelNodeImpl { throw new SpelEvaluationException(getStartPosition(), SpelMessage.FUNCTION_NOT_DEFINED, this.name); } if (!(value.getValue() instanceof Method)) { - // Two possibilities: a lambda function or a Java static method registered as a function + // Possibly a static Java method registered as a function throw new SpelEvaluationException( SpelMessage.FUNCTION_REFERENCE_CANNOT_BE_INVOKED, this.name, value.getClass()); }