hello thomas, i've uploaded a patch - see [1]. furthermore, i've uploaded the patched jar (+ source) - see [2].
regards, gerhard [1] http://issues.apache.org/jira/browse/EXTVAL-37 [2] http://people.apache.org/~gpetracek/myfaces/extval/issues/37/ 2009/2/28 Gerhard Petracek <[email protected]> > hello thomas, > > thank you for the detailed description! > this issue is solved in extval for jsf 1.2 -> if you have the possibility > to upgrade to jsf 1.2 + extval 1.2.x, you don't have this problem. > > @extval for jsf 1.1: i created an issue [1] > > regards, > gerhard > > [1] http://issues.apache.org/jira/browse/EXTVAL-37 > > > > 2009/2/27 <[email protected]> > > >> Hello, >> >> I'm sorry if this ends up in the wrong place, i'm new to this. >> I encountered a problem as i tried to use extval together with facelets >> >> extval 1.1.1 >> facelets 1.1.14 >> >> The Problem concerns the DefaultELHelper and a special case of EL usage in >> custom facelet tags. >> >> I am using custom composition tags in facelets like shown in this IBM >> article by Richard Hightower: >> http://www.ibm.com/developerworks/java/library/j-facelets/#N102EF >> >> custom tag inside a facelet: >> >> <my:customTag entity="#{viewBean}" fieldName="address" /> >> >> (the viewBean has an address property) >> >> >> custom tag source: >> >> <ui:composition> >> >> <h:selectOneMenu id="#{fieldName}_input" >> value="#{entity[fieldName]}" > >> <f:selectItem ... /> >> ... >> </h:selectOneMenu> >> >> </ui:composition> >> >> Problem and StackTrace: >> >> fieldName contains the String "address", which is what we want to be >> evaluated >> so we cant put the '' around the fieldName >> >> ValueBindingExpression = "#{entity[fieldName]}" >> >> result value = "entity[address]" >> >> => no '' around address >> >> code line 93: >> int index1 = expression.lastIndexOf("']"); >> >> expression does not contain '] but it contains ] >> therefore index1 and index2 are -1 and the else branch is executed >> which does not set base, so it remains null >> finally this leads to an exception >> >> Daemon Thread [http-8080-2] (Suspended (breakpoint at line 93 in >> ValueBindingExpression)) >> ValueBindingExpression.<init>(String) line: 93 >> DefaultELHelper.getValueBindingExpression(UIComponent, boolean) >> line: 104 >> DefaultELHelper.getPropertyDetailsOfValueBinding(UIComponent) line: >> 138 >> DefaultComponentMetaDataExtractor.extract(FacesContext, Object) >> line: 85 >> >> >> ValidationInterceptorWithSkipValidationSupport(ValidationInterceptor).initComponent(FacesContext, >> UIComponent) line: 74 >> >> >> ValidationInterceptorWithSkipValidationSupport(ValidationInterceptor).beforeEncodeBegin(FacesContext, >> UIComponent, Renderer) line: 53 >> >> >> ExtValGenericRendererWrapper(ExtValRendererWrapper).encodeBegin(FacesContext, >> UIComponent) line: 208 >> ExtValGenericRendererWrapper.intercept(Object, Method, Object[], >> MethodProxy) line: 71 >> >> HtmlMenuRenderer$$EnhancerByCGLIB$$ba4b3ba9.encodeBegin(FacesContext, >> UIComponent) line: not available >> HtmlSelectOneMenu(UIComponentBase).encodeBegin(FacesContext) line: >> 746 >> ComponentSupport.encodeRecursive(FacesContext, UIComponent) line: >> 242 >> ComponentSupport.encodeRecursive(FacesContext, UIComponent) line: >> 249 >> ComponentSupport.encodeRecursive(FacesContext, UIComponent) line: >> 249 >> FaceletViewHandler.renderView(FacesContext, UIViewRoot) line: 594 >> AjaxViewHandler(ViewHandlerWrapper).renderView(FacesContext, >> UIViewRoot) line: 101 >> AjaxViewHandler.renderView(FacesContext, UIViewRoot) line: 222 >> RenderResponseExecutor.execute(FacesContext) line: 41 >> LifecycleImpl.render(FacesContext) line: 146 >> FacesServlet.service(ServletRequest, ServletResponse) line: 147 >> ApplicationFilterChain.internalDoFilter(ServletRequest, >> ServletResponse) line: 290 >> ApplicationFilterChain.doFilter(ServletRequest, ServletResponse) >> line: 206 >> AuthorizationFilter.doFilter(ServletRequest, ServletResponse, >> FilterChain) line: 97 >> ApplicationFilterChain.internalDoFilter(ServletRequest, >> ServletResponse) line: 235 >> ApplicationFilterChain.doFilter(ServletRequest, ServletResponse) >> line: 206 >> ExtensionsFilter.doFilter(ServletRequest, ServletResponse, >> FilterChain) line: 246 >> ApplicationFilterChain.internalDoFilter(ServletRequest, >> ServletResponse) line: 235 >> ApplicationFilterChain.doFilter(ServletRequest, ServletResponse) >> line: 206 >> EncodingFilter.doFilter(ServletRequest, ServletResponse, >> FilterChain) line: 22 >> ApplicationFilterChain.internalDoFilter(ServletRequest, >> ServletResponse) line: 235 >> ApplicationFilterChain.doFilter(ServletRequest, ServletResponse) >> line: 206 >> ExtensionsFilter(ExtensionsFilter).doFilter(ServletRequest, >> ServletResponse, FilterChain) line: 301 >> ApplicationFilterChain.internalDoFilter(ServletRequest, >> ServletResponse) line: 235 >> ApplicationFilterChain.doFilter(ServletRequest, ServletResponse) >> line: 206 >> StandardWrapperValve.invoke(Request, Response) line: 233 >> StandardContextValve.invoke(Request, Response) line: 191 >> StandardHostValve.invoke(Request, Response) line: 128 >> ErrorReportValve.invoke(Request, Response) line: 102 >> StandardEngineValve.invoke(Request, Response) line: 109 >> CoyoteAdapter.service(Request, Response) line: 286 >> Http11AprProcessor.process(long) line: 857 >> Http11AprProtocol$Http11ConnectionHandler.process(long) line: 565 >> AprEndpoint$Worker.run() line: 1509 >> Thread.run() line: 619 >> >> without extval this expression evaluates and works fine, so i guess this >> is a lack of facelets/EL support. >> please correct me if i am wrong, and feel free to kill me if this is not >> the right place to report such a problem. >> >> kind regards, >> thomas >> >> -- http://www.irian.at Your JSF powerhouse - JSF Consulting, Development and Courses in English and German Professional Support for Apache MyFaces
