Yeah,
that is b/c of the real impl is in the -impl JAR.
ApplicationImpl.
but, the method is there, so there is something wrong in your setup
-M
On Sat, Jul 5, 2008 at 4:51 PM, Eivind Ronnevik <[EMAIL PROTECTED]> wrote:
> Hi again!
>
> I did the decompile, and (as I expected when seeing the source) the proper
> output is there.
>
> Application interface has method:
>
> public ExpressionFactory getExpressionFactory()
> {
> throw new UnsupportedOperationException();
> }
>
> And ApplicationImpl has method:
>
> public ExpressionFactory getExpressionFactory()
> {
> return _runtimeConfig.getExpressionFactory();
> }
>
> So the source has it, the decompiled class-files has it, and it's there in
> the javadoc. But still in eclipse I don't see it ;)
>
> I questioned the javax-libraries, because even though Application.class is
> part of javax.faces, ExpressionFactory is not, it belongs to javax.el
>
> :)
>
> Regards,
>
> Eivind
>
> -----Original Message-----
> From: Matthias Wessendorf [mailto:[EMAIL PROTECTED]
> Sent: 5. juli 2008 15:59
> To: MyFaces Discussion
> Subject: Re: Problem with missing methods in Application.class in Myfaces
> 1.2.3 ??
>
> On Sat, Jul 5, 2008 at 3:57 PM, Eivind Ronnevik <[EMAIL PROTECTED]> wrote:
>> Matthias,
>>
>> Thanks for your quick reply!
>>
>> Unfortunately, this was already my first thought.. So I created a brand new
>> project with only myfaces-1.2.3 in classpath, and in a stupid class I tried
>> to get the Application interface to see the available methods. Same result..
>
> hrm.
> can you open the MyFaces API JAR and decompile the Application.class file?
> it must be in there, if you are using MyFaces 1.2.x
>
>>
>> Could this be linked to some incorrect version of my javax - libraries?
>> (myfaces 1.2 requires JSP 2.1 and JSTL 1.2). Are there any references from
>> myfaces.apache.org on which libraries to use and where to get them?
>
> the application is part of javax.faces, which comes from myfaces.
>
> very strange.
>
> -M
>
>>
>> Best regards,
>>
>> Eivind
>>
>>
>> -----Original Message-----
>> From: Matthias Wessendorf [mailto:[EMAIL PROTECTED]
>> Sent: 5. juli 2008 15:33
>> To: MyFaces Discussion
>> Subject: Re: Problem with missing methods in Application.class in Myfaces
>> 1.2.3 ??
>>
>> Hi,
>>
>> I see the method here:
>> http://myfaces.apache.org/core12/myfaces-api/apidocs/javax/faces/application/Application.html#getExpressionFactory()
>>
>> perhaps you somehow have both libs in your clazzpath ?
>> -M
>>
>> On Sat, Jul 5, 2008 at 3:17 PM, Eivind Ronnevik <[EMAIL PROTECTED]> wrote:
>>> Hi!
>>>
>>>
>>>
>>> I've been working with Myfaces-1.1.5 for some time, but now decided to
>>> change to the 1.2 implementation, with myfaces-1.2.3 jars.
>>>
>>>
>>>
>>> I've had no problems in creating and deploying an application, but suddenly
>>> I hit a problem I don't understand
>>>
>>>
>>>
>>> I wanted to create a component programmatically (HtmlCommandLink), and set
>>> the action with the MethodBinding, as I've always done in myfaces-1.1.5:
>>>
>>>
>>>
>>> MethodBinding methodBinding =
>>> FacesContext.getCurrentInstance().getApplication().createMethodBinding(
>>>
>>> "#{myHandler.myAction}",null);
>>>
>>> htmlCommandLink.setAction( methodBinding )
>>>
>>>
>>>
>>> But then my IDE (Eclipse) reported this method (createMethodBinding) as
>>> deprecated. I had a look at the javadoc following the myfaces-1.2.3 bin, and
>>> from what I could understand there is a new way of doing this. Application
>>> interface should have a method getExpressionFactory() from which you would
>>> call the method createMethodExpression( ELContext, String, Class, Class[])
>>>
>>>
>>>
>>> But if I retrieve the Application object from my facesContext, I don't see
>>> this method. I only see the methods that I also did in myfaces-1.1.5, but
>>> the createMethodBinding() is now listed as deprecated. And I can't find
>>> ExpressionFactory in the list of possible classes either. I have had a look
>>> at the source of 1.2.3, and for what I can understand the ApplicationImpl
>>> provide this and other missing methods. The Application interface provides
>>> the methods as well, but throws UnsupportedOperationExceptions on those
>>> methods.
>>>
>>>
>>>
>>> Am I the stupid one here missing something obvious? Should I add some other
>>> libraries to use myaces-1.2.3, or are there any explanations to why I have
>>> this problem?
>>>
>>>
>>>
>>> Do I need to create my own implementation of the Application interface?
>>>
>>>
>>>
>>> Hope to have some quick answers to this one, because I'm really getting
>>> stuck here. J
>>>
>>>
>>>
>>> Regards,
>>>
>>>
>>>
>>> Eivind Rønnevik
>>>
>>>
>>>
>>>
>>
>>
>>
>> --
>> Matthias Wessendorf
>>
>> further stuff:
>> blog: http://matthiaswessendorf.wordpress.com/
>> sessions: http://www.slideshare.net/mwessendorf
>> mail: matzew-at-apache-dot-org
>>
>
>
>
> --
> Matthias Wessendorf
>
> further stuff:
> blog: http://matthiaswessendorf.wordpress.com/
> sessions: http://www.slideshare.net/mwessendorf
> mail: matzew-at-apache-dot-org
>
--
Matthias Wessendorf
further stuff:
blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
mail: matzew-at-apache-dot-org