[ 
https://issues.apache.org/jira/browse/MYFACES-2829?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12889980#action_12889980
 ] 

Mark Struberg commented on MYFACES-2829:
----------------------------------------

OMG, it's even more fuu.. up *cry*

from JSR-245 2.12.4 ExpressionFactory#createMethodExpression(ELContext, String, 
Class, Class[]):

expectedParamTypes - The expected parameter types for the method to be found. 
Must be an
array with no elements if there are no parameters expected. It is illegal to 
pass null, unless the method
is specified with arugments in the EL expression, in which case these arguments 
are used for method
selection, and this parameter is ignored.


As far as I read it: 
* if the action EL has no parameters -> paramTypes = new Class[0]
* if the action EL has parameters -> paramTypes = null

seems pretty complicated :(

> wrong BeanELResolver paramType invocation
> -----------------------------------------
>
>                 Key: MYFACES-2829
>                 URL: https://issues.apache.org/jira/browse/MYFACES-2829
>             Project: MyFaces Core
>          Issue Type: Bug
>          Components: JSR-314
>    Affects Versions: 2.0.1
>            Reporter: Mark Struberg
>
> Our facelets compiler currently invokes the BeanELResolver with param type 
> EMPTY_CLASS_ARRAY (Class[0]). 
> This is actually wrong, since 2.2.9 of the JSR-245 EL spec defines:
> http://jcp.org/aboutJava/communityprocess/mrel/jsr245/index.html
> 2.2.9 invoke(ELContext, Object, Object, Class[], Object[])
> paramTypes - An array of Class objects identifying the method's formal 
> parameter types, in declared
> order. Use an empty array if the method has no parameters. Can be null, in 
> which case the method's
> formal parameter types are assumed to be unknown.
> So for an empty Class[] there is NO method guess available. Suns el-impl 
> seems a bit more lenient than other EL implementations though.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to