123ArticleOnline Logo
Welcome to 123ArticleOnline.com!
ALL >> Technology,-Gadget-and-Science >> View Article

Facelets To Aid Java Development

Profile Picture
By Author: Dharmesh Aegis
Total Articles: 105
Comment this article
Facebook ShareTwitter ShareGoogle+ ShareTwitter Share

The kind of the java solutions offered to the IT sector is amazing these days. There has been a lot of java development happening these days with the increased number of outsource java development taking place. Facelets are one such java solutions tool, which is very powerful. It helps to organize and ensure java development projects become more efficient. Outsource java development team can avoid a catastrophe when they use facelets for devising innovative java solutions.
Here the various features that are either under used or newly introduced that is beneficial to java development.
Leveraging f of the ui: decorate
The ui: decorate allows the outsource java development team to change the skin from almost anything in the JSF page. Say for example the form fields are usually separated with the help of the section containers so with this ui: decorate try to give some charm to that by giving some attractive skins.

Now let us explain java development with the help of an example. Take the word "Hello Faceltes". Let's assume you want to decorate this text. You want it to have a green background ...
... and also a border should surround the background, which is green in color. This is how the coding needs to be done to get the desired result in Java solutions.
Listing 1. /WebContent/example/example1.xhtml
<!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:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html">

<body>

<h:form>

<ui:decorate template="/WEB-INF/widget/formDecorator.xhtml">Hello Facelets!</ui:decorate>...</h:form>

</body>

</html>
From the above it is very clear that one needs to only add two more lines extra in the coding to get the effect. So it is better to decorate the page as it will be more effective. So whatever you want to decorate see to that it is placed between the tags <ui:decorate...> and </ui:decorate>

A simple text can be decorated easily.
It is not difficult to include the form fields to the page and also decorate in the same way under Java development. The hello facelets should be just is replaced with the form fields that need to be decorated. The listing 2 in the decorator will have the form field decorator option. There will be templates which will be helpful in making the desired effect. To get the green effect the style sheet can be used. One can also choose to add some images that are very elite at the border of the form field. As the outsourced java development team modifies the decorator they will keep getting new affect every time with new color and skin. Given below is the coding give to decorate the form fields as part of Java solutions.
Listing 2. /WEB-INF/widget/formDecorator.xhtml
<!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:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html">

<style>

.wrapper { width: auto; }

* { border-color: #9CE6AE; }

.wrapper * { background-color: #DCFAB9; }

.wrapper .horizontalEdge, .wrapper .curvedEdge1, .wrapper .curvedEdge2, .wrapper .verticalEdge{

font-size: 1px;

display: block;

height: 1px;

overflow: hidden; }

.wrapper .curvedEdge1, .wrapper .curvedEdge2, .wrapper .verticalEdge{

border-width: 0px 1px 0px 1px;

border-style: solid; }

.wrapper .horizontalEdge {

border-style: solid;

border-width: 1px 0px 0px 0px;

margin: 0px 5px; }

.wrapper .curvedEdge1 { margin: 0px 3px; }

.wrapper .curvedEdge2 { margin: 0px 2px; }

.wrapper .verticalEdge { margin: 0px 1px; height:2px; }

.wrapper .content {

border-width: 0px 1px 0px 1px;

border-style: solid;

padding: 0px 5px; }

</style>
<table width="80%">

<tr>

<td>

<div class="wrapper">

<span>

<span class="horizontalEdge"></span>

<span class="curvedEdge1"></span>

<span class="curvedEdge2"></span>

<span class="verticalEdge"></span>

</span>

<div class="content"><ui:insert /></div>

<span>

<span class="verticalEdge"></span>

<span class="curvedEdge2"></span>

<span class="curvedEdge1" ></span>

<span class="horizontalEdge" ></span>

</span>

</div>

</td>

</tr>

</table>

</html>

For More Information:- Java Development | Java Solutions

Total Views: 246Word Count: 690See All articles From Author

Add Comment

Technology, Gadget and Science Articles

1. Extract Restaurant Info From Lieferando Germany For Market Insights
Author: Food Data Scrape

2. Erp For Small Business: Unlock Growth & Beat Your Rivals
Author: Alex Forsyth

3. Gain Sneaker Listings With Poizon Sneaker Data Scraping
Author: Retail Scrape

4. How Can A Doordash Dataset Help Data-driven Strategic Business Insights?
Author: Mobile App Scraping

5. Ai Creativity And The Rise Of Ai Art Generators | Impaakt
Author: Impaakt Magazine

6. Scrape Footlocker Product Data For Resale Success
Author: Actowiz Solutions

7. The Science Behind Nano Coating For Textiles And Sofas
Author: Vetro Power

8. Fabric Protection For Sofas_ A Profitable Value-add For Furniture Manufacturers
Author: Vetro Power

9. How Fabric Protection Can Extend The Life Of Your Commercial Spaces
Author: Vetro Power

10. Challenges In Integrating Organizational Change With Crm
Author: DialDesk

11. Insurance Portal Development: Key Features To Stay Ahead Of The Competition
Author: crmjetty

12. Amazon Usa | How Review Scraping Boosted Tech Brand Cx
Author: Mellisa Torres

13. How Does Web Scraping Help With Accurate Uber Eats Menu Price Tracking Methods?
Author: Retail Scrape

14. Scraping Zomato Data Uttarakhand: Food Insights Guide
Author: Actowiz Solutions

15. Why Enseur Is Among The Best Event Ticketing Platforms For Seamless Event Success
Author: Enseur Tech

Login To Account
Login Email:
Password:
Forgot Password?
New User?
Sign Up Newsletter
Email Address: