public static MethodExpression createMethodExpression ( String p_expression , Class < ? > returnType , Class < ? > ... parameterTypes ) { FacesContext context = FacesContext . getCurrentInstance ( ) ; ExpressionFactory expressionFactory = context . getApplication ( ) . getExpressionFactory ( ) ; ELContext elContext = context . getELContext ( ) ; MethodExpression mex = expressionFactory . createMethodExpression ( elContext , p_expression , returnType , parameterTypes ) ; return mex ; }
Utility method to create a JSF Method expression