composite-component

Inconsistent Composite Component clientId when using a MethodExpression attribute

你。 提交于 2019-12-12 19:37:20
问题 Hi suppose you have the following composite component: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xmlns:composite="http://java.sun.com/jsf/composite" > <composite:interface> <composite:attribute name="action" targets="#{cc.clientId}:value"/> </composite

Enum values in Composite Component attribute

南楼画角 提交于 2019-12-12 11:20:09
问题 My issue is quite simple : I want to create a composite component with a String attribute, Type. <cc:attribute name="type" /> This attribute will have 3 acceptable values, [TYPE1, TYPE2, TYPE3] Is it possible to say my component will accept only these values ? 回答1: Unfortunately no, you cannot put a compile/buildtime restriction on a composite component attribute value in the cc interface. You can however put a runtime restriction by checking the value in the cc implementation. <ui:param name

Should a composite component really require namingcontainer interface?

夙愿已清 提交于 2019-12-12 10:06:19
问题 I want to create a composite componet that can iterate with others. The problem is that composite componet is a namingcontainer and a simple selectOnMenu change and refresh other selectOnMenu do not is possible because "id" given to selectOnMenu is combo1:combo and can't see combo2:combo . The best situation would be form1:combo1 and form1:combo2 , then, combo1 and combo2 uses uinamingcontainer of h:form . This link talks about this but no solution. https://cwiki.apache.org/MYFACES/create-a

Proper using of Facelet templates & Composite Components

久未见 提交于 2019-12-12 08:47:05
问题 I'm still not sure about proper using of JSF Templates & Composite Components. I need create an enterprise web applications, which will have a lot of pages. Every page will have the same header, menu, footer and of course different content (= JSF template). The content on every pages will consist of reusable "boxes" (= JSF composite components). The boxes consist of some fileds, buttons etc. Is my solution proper? Or should I use other technology like , Custom Components, decorate ...? layout

JSF leaking memory through EL and composite components

╄→尐↘猪︶ㄣ 提交于 2019-12-12 07:59:25
问题 Note: I'm using mojarra 2.1.20 and rich faces 4.2.2. I've analyzed a heapdump and I've noticed that EL expressions reside in LRUMap in the session. Does anyone know why and what to do to avoid it? The problem I have is related to a composite component containing following line: <rich:select ... valueChangeListener="#{cc.listValuesChangeListener}" with backing bean my.package.MultiComboSelection. Obviously my.package.MultiComboSelection has a method defined named listValuesChangeListener. The

Composite Component with child- Composite Component: Not thread safe?

荒凉一梦 提交于 2019-12-11 18:52:09
问题 Does anybody know if passing objects as parameter from one composite component to another child composite component is thread-save? I have a composite component A that uses another composite component A' as child and passes an object as parameter cc.attrs.parameter to A'. A is used twice in the same form: Component A: <cc:interface> <cc:attribute name="value"/> </cc:interface> <cc:implementation> <cdef:myChildComponent value="${cc.attrs.value}"/> <!-- Show data from value --> </cc

How to make Eclipse autocomplete work with JSF composite components in JAR?

一个人想着一个人 提交于 2019-12-11 13:28:46
问题 Background / Problem I'm trying to create a reusable JSF composite component that can be shared between many applications by packaging the components in jars (similar to Deploy JSF composite components for shared use and JSF 2.0 composite component into jar). When trying to refer to these components in a facelets page of a web project in Eclipse, it doesn't autocomplete (content assist) the tags or attributes of my composite component. Using the same composite component jar in NetBeans works

Pass method expression attribute through to nested composite component

試著忘記壹切 提交于 2019-12-11 11:15:00
问题 I have composite component DocumentSelector , which contains another composite component modalWindow . <cc:interface componentType="selector.DocumentSelector"> <cc:attribute name="showSelector" method-signature="void listener(java.util.List)"/> </cc:interface> <cc:implementation> <div id="#{cc.clientId}"> <ccs:modalWindow id="modal_window" showListener="#{cc.showSelector}" mode="ajax"> </ccs:modalWindow> </div> </cc:implementation> I need to pass method #{cc.showSelector} to composite

JSF composite component childrens

最后都变了- 提交于 2019-12-11 10:31:52
问题 Is there any way using EL to retrieve a children list so i can iterate through it with <ul> <ui:repeat value="#{Magic El expression}" var="children" > <li> <p> #{children.title} *</p> </li> </ui:repeat> </ul> <div> <cc:insertChildren /> </div> * perhaps #{children.attrs.title} I don't know? What I'm trying to do here is create a Tab composite component. I know libraries such as primefaces offer tabview etc. Yet I need to create my own because of extended jquery functionality. Plus I'm working

How to update a composite component form from another composite component?

孤街浪徒 提交于 2019-12-11 07:48:34
问题 I'm having problem trying to update an external form. To be more clear, I have a primary form that includes 2 different composite components, lets call include1 and include2. The page I want to update is the include2 being update after a search from a include1. this is how the 2 pages are being included. <ui:define name="include1"> <ui:param name="mbean" value="#{currentBean}" /> <libcomp:include1 /> </ui:define> <ui:define name="include2"> <ui:param name="mbean" value="#{currentBean}" />