SlideShare a Scribd company logo
A Complete Tour of  JavaServer Faces 2.0 Jim Driscoll [email_address] Andy Schwartz [email_address]
What's new?
Almost Everything
Faces Expert Group Sun – Ed Burns, Roger Kitain (Spec leads)
Oracle
Apache
IceFaces
RichFaces
RedHat / Seam
Book Authors
Many more
All  of the Faces of Faces at Sun R Ed Burns Jim Driscoll Roger Kitain Ryan Lubke
Most  of the Faces of the EG Andy Schwartz Dan Allen Alexandr Smirnov Ken Paulsen Martin Marinschek Pete Muir Kito Mann Joe Ottinger Ted Goddard Neil Griffin Jason Lee David Geary Mike Freedman Gavin King R Jeremy Grelle Keith Donald Ed Burns Jim Driscoll Roger Kitain Ryan Lubke
Some  Faces of the Faces Community Andy Schwartz Dan Allen Jacob Hookom Alexandr Smirnov Ken Paulsen Martin Marinschek Matthias We ßendorf Pete Muir Alexander Jesse Imre O ßwald Yara Senger Lincoln Baxter III Adam Winer Craig McClanahan Kito Mann Rick Hightower Joe Ottinger Ted Goddard Neil Griffin Jason Lee Stan Silvert David Geary Mike Freedman Gavin King Hazem Saleh Çağatay Çivici Dennis Byrne Roger Keays Amy Fowler Max Katz R Jeremy Grelle Keith Donald
Community Ideas Innovation happens everywhere
Most ideas were proven in the community before adoption
Some approaches (i.e., Ajax) required a good deal of merging
Highlights on each feature
Features, features
Facelets
Facelets Almost exactly the same as existing Facelets technology
JSP still supported, but... All new features will be in Facelets
Facelets now the preferred View Declaration Language Designed for JSF from the beginning
Facelets XHTML based – document validation
Better error handling, including line numbers
Library prefixes as namespaces
EL directly in page: #{bean.propertyname} Templating made easy ui:composition, ui:define, ui:insert
ui:include, ui:repeat
Composite Components
This...
Becomes this...
Or maybe this:
Composite Components Enable True Abstraction Create a true, reusable, component from an arbitrary region of a page
Built by composing other components Full support for using attached objects in the using page, and mapping them to arbitrary targets within the composite component Action methods
Validators, etc
Composite Components Builds on top of Resources and Facelets
Heavily leverages naming conventions Resource dir
Library name is directory name
Tag name is file name Essentially special-case templating
Composite Component In file ctx-root/resources/simpleout/out.xhtml: <composite:interface> <composite:attribute name=&quot;value&quot;  required=&quot;true&quot;/> </composite:interface> <composite:implementation> <h:outputText value=&quot;#{cc.attrs.value}&quot;  style=&quot;background-color: yellow&quot;/> </composite:implementation>
Composite Component <html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xmlns:h=&quot;http://java.sun.com/jsf/html&quot; xmlns:f=&quot;http://java.sun.com/jsf/core&quot; xmlns:ez=&quot;http://java.sun.com/jsf/composite/simpleout&quot;> .... <ez:out value=&quot;Test Value&quot;/> ....
Ajax
Ajax Inspiration: ADF Faces, RichFaces, IceFaces, DynamicFaces
Two entry points: Declarative:  <f:ajax>  tag, uses  AjaxBehavior
Programmatic ajax: resource library  javax.faces , resource name  jsf.js , JavaScript namespace  jsf.ajax.  jsf.ajax.request  function
Ajax Declarative ajax: useful to ajaxify non ajax pages Add ajax behaviors “invisibly”
Supports many Ajax usecases JavaScript Ajax API usage pattern jsf.ajax.request()  JavaScript function
Integrate with existing Ajax widgets Simplify lifecycle view: execute and render
Ajax Tag Example <h:outputText  id=&quot;out1&quot;  value=&quot;#{count.count}&quot;/> <h:commandButton value=&quot;Count&quot;> <f:ajax render=”out1”/> </h:commandButton>
Partial State Saving
Partial State Saving Inspired by Trinidad state saving
Save only the state that's changed since creation of the component tree
Per-view state size up to 4X smaller than before
Default for pages written with Facelets
Of interest to Java custom component authors
All standard components implement this feature - your composite components will automatically take advantage of it.
Partial State Saving PartialStateHolder  behavioral interface, extends existing  StateHolder . PartialStateHolder.markInitialState() StateHelper , from  UIComponent , does most of the work: replace ivars with keys within  StateHelper No longer need custom saveState/restoreState() implementations
Simplify Custom Components public class MyInput extends  UIComponentBase { private enum Keys { name } public String getName() { return getStateHelper().get(name); } public void setName(String nameParam) { getStateHelper().put(name, nameParam); } }
View Parameters
View Parameters Inspired by Page Parameters from JBoss Seam
Provides a way to map request parameters to special components within the view
<f:metadata>
<f:viewParam>

More Related Content

PDF
Jsf intro
vantinhkhuc
 
PPT
JSF Component Behaviors
Andy Schwartz
 
PPTX
Introduction to jsf 2
yousry ibrahim
 
PDF
Java server faces
Fábio Santos
 
PPT
Java Server Faces (JSF) - advanced
BG Java EE Course
 
PPTX
Jsf presentation
Ashish Gupta
 
PPT
Jsf2.0 -4
Vinay Kumar
 
PPT
Java Server Faces (JSF) - Basics
BG Java EE Course
 
Jsf intro
vantinhkhuc
 
JSF Component Behaviors
Andy Schwartz
 
Introduction to jsf 2
yousry ibrahim
 
Java server faces
Fábio Santos
 
Java Server Faces (JSF) - advanced
BG Java EE Course
 
Jsf presentation
Ashish Gupta
 
Jsf2.0 -4
Vinay Kumar
 
Java Server Faces (JSF) - Basics
BG Java EE Course
 

What's hot (20)

PPT
JSF basics
airbo
 
PPTX
Introduction to JSF
SoftServe
 
PPT
Spring 3.x - Spring MVC
Guy Nir
 
PPT
Struts Introduction Course
guest764934
 
PPT
Spring MVC
yuvalb
 
PPTX
Spring Web MVC
zeeshanhanif
 
ODP
Spring Portlet MVC
John Lewis
 
PPT
Spring MVC Basics
Bozhidar Bozhanov
 
PPT
Spring MVC 3.0 Framework
Ravi Kant Soni ([email protected])
 
ODP
Java Spring MVC Framework with AngularJS by Google and HTML5
Tuna Tore
 
PPTX
Spring MVC
Emprovise
 
PPTX
Java server faces
owli93
 
PPTX
Spring 3.x - Spring MVC - Advanced topics
Guy Nir
 
PDF
Sun JSF Presentation
Gaurav Dighe
 
PPTX
Java Server Faces + Spring MVC Framework
Guo Albert
 
PPTX
9. java server faces
AnusAhmad
 
PDF
Lecture 10 - Java Server Faces (JSF)
Fahad Golra
 
PDF
Spring MVC 3.0 Framework (sesson_2)
Ravi Kant Soni ([email protected])
 
PPTX
Spring MVC Architecture Tutorial
Java Success Point
 
JSF basics
airbo
 
Introduction to JSF
SoftServe
 
Spring 3.x - Spring MVC
Guy Nir
 
Struts Introduction Course
guest764934
 
Spring MVC
yuvalb
 
Spring Web MVC
zeeshanhanif
 
Spring Portlet MVC
John Lewis
 
Spring MVC Basics
Bozhidar Bozhanov
 
Spring MVC 3.0 Framework
Ravi Kant Soni ([email protected])
 
Java Spring MVC Framework with AngularJS by Google and HTML5
Tuna Tore
 
Spring MVC
Emprovise
 
Java server faces
owli93
 
Spring 3.x - Spring MVC - Advanced topics
Guy Nir
 
Sun JSF Presentation
Gaurav Dighe
 
Java Server Faces + Spring MVC Framework
Guo Albert
 
9. java server faces
AnusAhmad
 
Lecture 10 - Java Server Faces (JSF)
Fahad Golra
 
Spring MVC 3.0 Framework (sesson_2)
Ravi Kant Soni ([email protected])
 
Spring MVC Architecture Tutorial
Java Success Point
 
Ad

Viewers also liked (8)

PPTX
JSF 2.2
Edward Burns
 
PPT
Jsf
Nguyen Tran
 
PDF
Curso de Java server faces (JSF)
Rafael Ponte
 
PPTX
JavaScript Presentation Frameworks and Libraries
Oleksii Prohonnyi
 
PDF
Spring Framework - Core
Dzmitry Naskou
 
PPT
Js ppt
Rakhi Thota
 
PPT
JavaScript - An Introduction
Manvendra Singh
 
PDF
reveal.js 3.0.0
Hakim El Hattab
 
JSF 2.2
Edward Burns
 
Curso de Java server faces (JSF)
Rafael Ponte
 
JavaScript Presentation Frameworks and Libraries
Oleksii Prohonnyi
 
Spring Framework - Core
Dzmitry Naskou
 
Js ppt
Rakhi Thota
 
JavaScript - An Introduction
Manvendra Singh
 
reveal.js 3.0.0
Hakim El Hattab
 
Ad

Similar to A Complete Tour of JSF 2 (20)

PDF
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
Arun Gupta
 
PDF
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
Arun Gupta
 
PPT
JSF 2 and beyond: Keeping progress coming
Andy Schwartz
 
PDF
JSF 2.0 Preview
Skills Matter
 
PDF
JavaServer Faces 2.0 - JavaOne India 2011
Arun Gupta
 
PDF
In The Brain of Cagatay Civici: Exploring JavaServer Faces 2.0 and PrimeFaces
Skills Matter
 
ODP
JSF 2.0 (JavaEE Webinar)
Roger Kitain
 
PPT
Facelets
lingli1031
 
PPT
What's new and exciting with JSF 2.0
Michael Fons
 
PPT
Component Framework Primer for JSF Users
Andy Schwartz
 
PPT
Facelets
cagataycivici
 
PDF
A Peek At The Future: Going Beyond JavaServer Faces 2.0 With RichFaces 4
balunasj
 
PPT
Jsfsunum
cagataycivici
 
PPT
Mastering OmniFaces - A Problem to Solution Approach
Anghel Leonard
 
PDF
Going Above JSF 2.0 with RichFaces and Seam
Lincoln III
 
PDF
What You Need To Build Cool Enterprise Applications With JSF
Max Katz
 
PPT
Rich faces
BG Java EE Course
 
PPTX
JSF.pptx
ubaidullah75790
 
PPT
JSF and Seam
yuvalb
 
PPTX
Introducing jee7 – jsf 2
Mihalis Kouziakis
 
Spark IT 2011 - Simplified Web Development using Java Server Faces 2.0
Arun Gupta
 
Hyperproductive JSF 2.0 @ JavaOne Brazil 2010
Arun Gupta
 
JSF 2 and beyond: Keeping progress coming
Andy Schwartz
 
JSF 2.0 Preview
Skills Matter
 
JavaServer Faces 2.0 - JavaOne India 2011
Arun Gupta
 
In The Brain of Cagatay Civici: Exploring JavaServer Faces 2.0 and PrimeFaces
Skills Matter
 
JSF 2.0 (JavaEE Webinar)
Roger Kitain
 
Facelets
lingli1031
 
What's new and exciting with JSF 2.0
Michael Fons
 
Component Framework Primer for JSF Users
Andy Schwartz
 
Facelets
cagataycivici
 
A Peek At The Future: Going Beyond JavaServer Faces 2.0 With RichFaces 4
balunasj
 
Jsfsunum
cagataycivici
 
Mastering OmniFaces - A Problem to Solution Approach
Anghel Leonard
 
Going Above JSF 2.0 with RichFaces and Seam
Lincoln III
 
What You Need To Build Cool Enterprise Applications With JSF
Max Katz
 
Rich faces
BG Java EE Course
 
JSF.pptx
ubaidullah75790
 
JSF and Seam
yuvalb
 
Introducing jee7 – jsf 2
Mihalis Kouziakis
 

Recently uploaded (20)

PPTX
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
PPTX
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
PPTX
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
PDF
Security features in Dell, HP, and Lenovo PC systems: A research-based compar...
Principled Technologies
 
PDF
Responsible AI and AI Ethics - By Sylvester Ebhonu
Sylvester Ebhonu
 
PDF
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
PPTX
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
PDF
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
The Future of Mobile Is Context-Aware—Are You Ready?
iProgrammer Solutions Private Limited
 
PPTX
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
PDF
Oracle AI Vector Search- Getting Started and what's new in 2025- AIOUG Yatra ...
Sandesh Rao
 
PDF
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
PPTX
Simple and concise overview about Quantum computing..pptx
mughal641
 
PDF
The Future of Artificial Intelligence (AI)
Mukul
 
PDF
AI-Cloud-Business-Management-Platforms-The-Key-to-Efficiency-Growth.pdf
Artjoker Software Development Company
 
PPTX
IT Runs Better with ThousandEyes AI-driven Assurance
ThousandEyes
 
PPTX
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
PPTX
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
PDF
SparkLabs Primer on Artificial Intelligence 2025
SparkLabs Group
 
Applied-Statistics-Mastering-Data-Driven-Decisions.pptx
parmaryashparmaryash
 
Agile Chennai 18-19 July 2025 | Emerging patterns in Agentic AI by Bharani Su...
AgileNetwork
 
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
Security features in Dell, HP, and Lenovo PC systems: A research-based compar...
Principled Technologies
 
Responsible AI and AI Ethics - By Sylvester Ebhonu
Sylvester Ebhonu
 
How ETL Control Logic Keeps Your Pipelines Safe and Reliable.pdf
Stryv Solutions Pvt. Ltd.
 
Dev Dives: Automate, test, and deploy in one place—with Unified Developer Exp...
AndreeaTom
 
Orbitly Pitch Deck|A Mission-Driven Platform for Side Project Collaboration (...
zz41354899
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
The Future of Mobile Is Context-Aware—Are You Ready?
iProgrammer Solutions Private Limited
 
Agile Chennai 18-19 July 2025 Ideathon | AI Powered Microfinance Literacy Gui...
AgileNetwork
 
Oracle AI Vector Search- Getting Started and what's new in 2025- AIOUG Yatra ...
Sandesh Rao
 
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
Simple and concise overview about Quantum computing..pptx
mughal641
 
The Future of Artificial Intelligence (AI)
Mukul
 
AI-Cloud-Business-Management-Platforms-The-Key-to-Efficiency-Growth.pdf
Artjoker Software Development Company
 
IT Runs Better with ThousandEyes AI-driven Assurance
ThousandEyes
 
New ThousandEyes Product Innovations: Cisco Live June 2025
ThousandEyes
 
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
SparkLabs Primer on Artificial Intelligence 2025
SparkLabs Group
 

A Complete Tour of JSF 2

Editor's Notes

  • #2: Heading should be V3 Express? Change the dates and names
  • #41: test
  • #64: Heading should be V3 Express? Change the dates and names