Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Facelets support

456776Feb 6 2006 — edited May 20 2006
Does anyone know if there will be impending facelets support? I'm really looking for something that will do code completion (insight) using tag namespaces in xhtml files.

Comments

dvohra21
A Facelet application may be generated in JDeveloper 10.1.3.
A .jsp file with JSP XML syntax may be used instead of a .xhtml file.
Facelets binaries:
https://facelets.dev.java.net/

Facelets support is added to faces-config.xml with
<application>
<view-handler>
com.sun.facelets.FaceletViewHandler
</view-handler>
</application>
dvohra21
To develop a Facelets application in JDeveloper 10.1.3

1. Add Facelets JAR files to a Facelets project.

<facelets-1.0.12>/ jsf-facelets.jar
<JDeveloper10.1.3>/jsf-ri/jsf-api.jar
<JDeveloper10.1.3>/jsf-ri/jsf-impl.jar
<JDeveloper10.1.3>/jakarta-struts/lib/ commons-beanutils.jar
<JDeveloper10.1.3>/jakarta-struts/lib/ commons-collections.jar
<JDeveloper10.1.3>/jakarta-struts/lib/ commons-digester.jar
<JDeveloper10.1.3>/jakarta-struts/lib/ commons-logging.jar
<facelets-1.0.12>/lib/el-ri.jar
<facelets-1.0.12>/lib/el-api.jar

2. Create a JSF JSP page. Convert the JSP page to JSP XML Sytax by adding
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:ui="http://java.sun.com/jsf/facelets"> </jsp:root>

xmlns:ui="http://java.sun.com/jsf/facelets" is the Facelets namespace.

3. To faces-config.xml add:
<application>
<view-handler>
com.sun.facelets.FaceletViewHandler
</view-handler>
</application>

4. To web.xml add
<context-param>
<param-name>javax.faces.DEFAULT_SUFFIX</param-name>
<param-value>.jsp</param-value>
</context-param>

In web.xml file, also specify the servlet mapping for the Faces Servlet.

<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.jsp</url-pattern>
</servlet-mapping>

5. To JSP page add tags from Facelets namespace.

6. Facelets navigation is similar to JSF navigation, and is specified in faces-config.xml.
498986
Is it possible to enable code insight for "XMLNS"?
If I create a "jsp jsf page" with following header, the code insight is not working for that tags:
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" version="2.0"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:ui="http://java.sun.com/jsf/facelets"> </jsp:root>

So if I type "<h:" no popup is appearing with the attributes for that element.
How can I turn on that feature for any tag space?

Would be great if someone could give me a hint :-)
498986
Is it not possible?
1 - 4
Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Jun 17 2006
Added on Feb 6 2006
4 comments
2,528 views