Hi

Its' managed-bean-name, not member-bean-name. This is the implicit mapping
that Shale does.


Hermod


-----Opprinnelig melding-----
Fra: AM101 [mailto:[EMAIL PROTECTED] 
Sendt: 27. april 2007 19:45
Til: user@shale.apache.org
Emne: Re: SV: SV: SV: SV: How to initialize a bean before initial display


I added backing bean entry in my faces-config.xml file:
   <managed-bean>
                <managed-bean-name>jspx$login</managed-bean-name>
        
<managed-bean-class>com.foo.ui.view.backing.Login</managed-bean-class>
                <managed-bean-scope>request</managed-bean-scope>
   </managed-bean>

and I also added <!-- ### clay:page charset="UTF-8" /### --> in my
login.jspx page. But now I get ReferenceSyntaxException. 

Stack Trace:
################################################################

Servlet.service() for servlet jsp threw exception
javax.faces.el.ReferenceSyntaxException: Invalid expression:
'[EMAIL PROTECTED]'
        at
org.apache.myfaces.el.ELParserHelper.parseExpression(ELParserHelper.java:97)
        at
org.apache.myfaces.el.ValueBindingImpl$2.newInstance(ValueBindingImpl.java:8
2)
        at
org.apache.myfaces.shared_impl.util.BiLevelCacheMap.get(BiLevelCacheMap.java
:123)
        at
org.apache.myfaces.el.ValueBindingImpl.<init>(ValueBindingImpl.java:115)
        at
org.apache.myfaces.application.ApplicationImpl$1.newInstance(ApplicationImpl
.java:64)
        at
org.apache.myfaces.shared_impl.util.BiLevelCacheMap.get(BiLevelCacheMap.java
:123)
        at
org.apache.myfaces.application.ApplicationImpl.createValueBinding(Applicatio
nImpl.java:617)
        at
javax.faces.webapp.UIComponentTag.createComponentInstance(UIComponentTag.jav
a:708)
        at
javax.faces.webapp.UIComponentTag.findComponent(UIComponentTag.java:596)
        at
javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:312)
        at
oracle.adf.view.faces.webapp.UIXComponentTag.doStartTag(UIXComponentTag.java
:85)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_af_outputText_0(login_jspx.java:10
56)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_cellFormat_7(login_jspx.java:1
034)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_rowLayout_5(login_jspx.java:10
10)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_tableLayout_4(login_jspx.java:
966)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_af_form_0(login_jspx.java:941)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_cellFormat_6(login_jspx.java:9
18)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_rowLayout_4(login_jspx.java:81
6)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_tableLayout_3(login_jspx.java:
689)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_cellFormat_3(login_jspx.java:6
62)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_rowLayout_2(login_jspx.java:55
8)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_tableLayout_2(login_jspx.java:
534)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_cellFormat_1(login_jspx.java:5
08)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_rowLayout_1(login_jspx.java:48
1)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_tableLayout_1(login_jspx.java:
459)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_cellFormat_0(login_jspx.java:4
34)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_rowLayout_0(login_jspx.java:41
1)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_tableLayout_0(login_jspx.java:
389)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_body_0(login_jspx.java:364)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_afh_html_0(login_jspx.java:262)
        at
org.apache.jsp.jspx.login_jspx._jspx_meth_f_view_0(login_jspx.java:229)
        at org.apache.jsp.jspx.login_jspx._jspService(login_jspx.java:199)
        at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
        at
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:3
34)
        at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
        at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Application
FilterChain.java:252)
        at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterCh
ain.java:173)
        at
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.
java:672)
        at
org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDis
patcher.java:463)
        at
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatch
er.java:398)
        at
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher
.java:301)
        at
org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(Servl
etExternalContextImpl.java:416)
        at
org.apache.myfaces.application.jsp.JspViewHandlerImpl.renderView(JspViewHand
lerImpl.java:234)
        at
oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHan
dlerImpl.java:157)
        at
org.apache.shale.clay.faces.ClayViewHandler.renderView(ClayViewHandler.java:
450)
        at
org.apache.shale.view.faces.ViewViewHandler.renderView(ViewViewHandler.java:
147)
        at
org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:384)
        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:138)

###############################################################


Hermod Opstvedt wrote:
> 
> Hi
> 
> What is the name of the view and bean?
> 
> Example:
> 
> If yor view is /lists.jsf the the bean must be defined as lists
> 
> If your view is /member/info.jsf, then the bean must be defined as
> member$info
> 
> And so on.
> 
> Hermod
> 
> 
> -----Opprinnelig melding-----
> Fra: AM101 [mailto:[EMAIL PROTECTED] 
> Sendt: 27. april 2007 16:50
> Til: user@shale.apache.org
> Emne: Re: SV: SV: SV: How to initialize a bean before initial display
> 
> 
> My backing bean is request-scoped and it is mapped in faces-config.xml. 
> 
> But I am using ADF and now I want to use shale going forward. I added
> shale-application.jar, shale-core.jar and shale-view.jar to my existing
> library. I also modified web.xml and added following entries:
> 
> <!-- Shale Application Controller Filter -->
>       <filter>
>               <filter-name>shale</filter-name>
>               <filter-class>
>       
> org.apache.shale.application.faces.ShaleApplicationFilter
>               </filter-class>
>       </filter>
> 
>       <!-- Shale Application Controller Filter Mapping -->
>       <filter-mapping>
>               <filter-name>shale</filter-name>
>               <url-pattern>/*</url-pattern>
>       </filter-mapping>
> 
> I don't get any exception at startup and My backing bean is extending
> AbstractViewController but init() method is never called by the
> controller.
> 
> 
> 
> 
> Hermod Opstvedt wrote:
>> 
>> Hi
>> 
>> If its not called, you must have placed it in session-scope (it must be
>> request-scoped), or it is not mapped against the view in faces-config.xml
>> 
>> Hermod
>> 
>> 
>> -----Opprinnelig melding-----
>> Fra: AM101 [mailto:[EMAIL PROTECTED] 
>> Sendt: 26. april 2007 23:54
>> Til: user@shale.apache.org
>> Emne: Re: SV: SV: How to initialize a bean before initial display
>> 
>> 
>> Thanks for your reply. I am now extending AbstractViewController and
>> implemented the init() method but this method is never called. do I need
>> to
>> configure anything? I am new to Shale, I appreciate your help.
>> 
>> 
>> 
>> Hermod Opstvedt wrote:
>>> 
>>> Hi
>>> 
>>> In that case you can initialize it in the init method or prerender
>>> method
>>> of
>>> the viewcontroller.
>>> 
>>> Hermod
>>> 
>>> 
>>> -----Opprinnelig melding-----
>>> Fra: AM101 [mailto:[EMAIL PROTECTED] 
>>> Sendt: 26. april 2007 21:22
>>> Til: user@shale.apache.org
>>> Emne: Re: SV: How to initialize a bean before initial display
>>> 
>>> 
>>> It is a view backing bean.
>>> 
>>> 
>>> 
>>> Hermod Opstvedt wrote:
>>>> 
>>>> Hi
>>>> 
>>>> What type of bean? Is it ViewController or what?
>>>> 
>>>> Hermod
>>>> 
>>>> 
>>>> -----Opprinnelig melding-----
>>>> Fra: AM101 [mailto:[EMAIL PROTECTED] 
>>>> Sendt: 26. april 2007 17:30
>>>> Til: user@shale.apache.org
>>>> Emne: How to initialize a bean before initial display
>>>> 
>>>> 
>>>> How do I initialize a bean before initial display? I want to populate
>>>> bean
>>>> values from database table. 
>>>> 
>>>> I can do it in the constructor, phase listener or by adding additional
>>>> getter method to initialize the bean. But is there any better way?
>>>> 
>>>> -- 
>>>> View this message in context:
>>>>
>>>
>>
>
http://www.nabble.com/How-to-initialize-a-bean-before-initial-display-tf3652
>>>> 365.html#a10202810
>>>> Sent from the Shale - User mailing list archive at Nabble.com.
>>>> 
>>>> 
>>>> 
>>>> 
>>> 
>>> -- 
>>> View this message in context:
>>>
>>
>
http://www.nabble.com/How-to-initialize-a-bean-before-initial-display-tf3652
>>> 365.html#a10206968
>>> Sent from the Shale - User mailing list archive at Nabble.com.
>>> 
>>> 
>>> 
>>> 
>> 
>> -- 
>> View this message in context:
>>
>
http://www.nabble.com/How-to-initialize-a-bean-before-initial-display-tf3652
>> 365.html#a10209745
>> Sent from the Shale - User mailing list archive at Nabble.com.
>> 
>> 
>> 
>> 
> 
> -- 
> View this message in context:
>
http://www.nabble.com/How-to-initialize-a-bean-before-initial-display-tf3652
> 365.html#a10220616
> Sent from the Shale - User mailing list archive at Nabble.com.
> 
> 
> 
> 

-- 
View this message in context:
http://www.nabble.com/How-to-initialize-a-bean-before-initial-display-tf3652
365.html#a10223552
Sent from the Shale - User mailing list archive at Nabble.com.


Reply via email to