|
View:
New views
5 Messages
—
Rating Filter:
Alert me
|
|
|
How to migrate JSF components to faceletsHi!
I have been given the task to migrate a JSF application that is JSP based to Facelets. I managed to migrate most of the pages that were using standard MyFaces and RichFaces components to Facelets without any major problem. But now I am facing problems with the in-house developed components. As far as I understand, I need to create a Facelets taglib and make the components declarations available there. So far I haven't had much of a sucess with these components. I already went through a few web sites, but so far I haven't found how the <component/> section really works. Is the <component-type/> the same as in the faces-config.xml file? What can I use there, if the component does not declare a proper <component-type/>. The components are mostly extending UIComponentBase and UIComponentBodyTag. Would I need to re-implement the components? The documentation also mentions a <component-class/>, but from the DTD that is not available. Thanks in advance, Paulo |
|
|
|
|
|
Re: How to migrate JSF components to faceletsHi,
after sometime playing around with it, I managed to do it. Thanks, Paulo On Mon, Feb 2, 2009 at 10:43 PM, Raymond K. DeCampo <rkdecampo@...> wrote:
|
|
|
Re: How to migrate JSF components to faceletsHi Paulo,
Can you share how you solved the problem? Thanks, Bruno. 2009/2/3 Paulo Pinto <pjmlp@...> Hi, |
|
|
Re: How to migrate JSF components to faceletsOlá Bruno, :)
my major problem was that I'm a Facelets newbie, so what I'm going to explain might be a well known procedure for some people on the list. So my issue was that I had to create a tag library description for a set of components that were either home made, or extensions from MyFaces/RichFaces components that the application is using. I spent some time looking at the faces-config.xml file and to the tld files, without understanding where the <component-type/> and <renderer-type/> would come from. On the faces-config.xml file that I had it was not easy to see the relationship between the components and render kit section. Then I realized that Facelets does not make use of the xxxxTag class, which is where the methods getComponentType() and getRendererType() are defined. Then it was pretty easy to create our tag library description. This might be pretty obvious if you have been doing JSF components for some time, but not me as I mentioned already. One thing that made me even more confused when I was trying to understand the way Facelets tags are declared was out of date documentation. If you go to https://facelets.dev.java.net/nonav/docs/dev/docbook.html, section 3.5.2. UIComponents. It says to use <component-class/> on a tag declaration, but this isn't available on recent versions of Facelets. Anyway, I understood what I need to be done and it is now working. -- Paulo On Tue, Feb 3, 2009 at 3:01 PM, Bruno Souza <bruno.nogueira.souza@...> wrote: Hi Paulo, |
| Free embeddable forum powered by Nabble | Forum Help |