SlideShare uma empresa Scribd logo
1 de 65
Baixar para ler offline
Rapid JSF Component
        Development   RichFaces CDK
JSF
Component
Libraries




      “...are essential part of
      JSF ecosystem, delivering
      great user experience”
“Components encapsulates complex
  logic, which is exposed with easy to use
  interface”




Proper
Level of
Abstraction
Building
Blocks




    “Components inter-cooperates
    in order to build complex application
    logic.”
“But what to do when is same
component missing in your favorite
component library?”
“Fortunately there are many JavaScript widget
libraries, which can be simply
used just for your needs”




                                   Bootstrap
Only for JavaScript kiddies?
“It's very simply to use these widgets,
they have as accessible API as JSF components”
“It is like going to library and choosing
book which best fit in your mood -
you can go and reuse JS widget”
4
ways
of reusing
JavaScript
widgets
#1   Direct JavaScript
#2   JSF Component
#3   JSF Composite Component
#4   RichFaces CDK
#1 Direct JavaScript
“Imagine big JSF application where you started
incorporating JavaScript widgets:
looks inconsistent and hardly readable.”
#2 JSF Component
“Let's build custom JSF component...”
What is component?
What is component?
   Tag
“Tag is representation of the component
in the page template code”
What is component?
   Tag
   Component Interface
“The component provides interface
for changing its configuration”




                                    Component
“This is source code of JSF component
a4j:commandLink”
“This is source code of JSF component
a4j:commandLink.”

“Let's look at the fragment.”
“The component is interface with list attributes,
     Represented as getters/setters of the component
     class”




“Each getter and setter just delegates to StateHelper
to keep the state of the component between subsequent
requests”
What is component?
   Tag
   Component Interface
   Renderer
“A renderer is responsible for translating
 the component to the page representation
 and then encoding the user input back to the
 component instance”



Component




Renderer
“A renderer is as verbose as
component code,
let's look at the sample of
h:dataTable component's
code”
“The renderer uses ResponseWriter
to add elements, attributes and text
content to the page.”

“The Java representation of the
renderer is very verbose, which leads
to readability and maintainability
concerns.”
What is component?
   Tag
   Component interface
   Renderer
   XML descriptors
     ●   taglib.xml
“taglib.xml descriptor is responsible for binding
the component from the page template
to the component class”



                                    Component




                                     Renderer
What is component?
   Tag
   Component interface
   Renderer
   XML descriptors
     ●   taglib.xml
     ●   faces-config.xml
“Faces-config.xml registers component into JSF ecosystem”




JSF
                                Component




                                  Renderer
What is component?
   Tag
   Component interface
   Renderer
   XML descriptors
     ●   faces-config.xml
     ●   taglib.xml
   Documentation
“Documentation is necessary for easiness of reuse of the components.”
But developing and maintaining all of these informations
is not really the way how to develop components
in the big scale.
#2 Composite Components
Composite Components
●   JSF2 feature
●   Provides XML representation
●   Allowing to write
    ●   HTML directly
    ●   Or compose JSF components
●   Developer needs to provide
    ●   Interface
    ●   Implementation
Rapid Turnaround
●   In the Development stage of the project
    ●   The composite component can be reloaded
    ●   Just with change of the source
But...
Immature / Incomplete
●   CC have still issues:
    ●   Partial state saving
        –   JAVASERVERFACES-2040
    ●   AJAX
        –   JAVASERVERFACES-1825
    ●   Submitted UIInput gets lost
        –   JAVASERVERFACES-1991
CC works great for composition of components
But they don't replace full-fledged component
                 development
Full-Fledged Development?
   Tag
   XML descriptors
     ●   faces-config.xml
     ●   taglib.xml
   Component interface
   Renderer
   Documentation

                            “So it means we need to get stuck with
                            full-fledged component development?”
What we actually need?
   Tag
   XML descriptors
     ●   faces-config.xml
     ●   taglib.xml
   Component interface
   Renderer (XML)
   Documentation
                            “Let's imagine that the most of the informations
                            are duplicates, which are actually expressed
                            by Component interface”
“And at this point, you recognize that some toolkit
may be needed to do the job!”
“Which is exactly what RichFaces CDK offers!”




         RichFaces CDK
        Component Development Kit
RichFaces CDK
●   Renderer
    ●   XML Templates
    ●   with syntax very close to Composite Components


●   Generated in the build-time
●   with Convention-over-Configuration in mind
But it is build-time tool, right?
Is it not too heavy-weight to use in development?
Rapid Turnaround
●   You can just use your IDE
●   And let Java Hot Deployment solutions to do
    the job
    ●   JRebel works very nice here
Resource Development
●   But Resources are as needed to develop
    rapidly as component/renderer code
    ●   JavaScript
    ●   CSS
●   Hot Deployment
    ●   using JSF application Development stage
Development Demo
Bootstrap




“Nothing prevents you to wrap all those libraries!”
Date-picker
Development Demo
Let's wrap those widgets!
Right level of abstraction
●   Let's take
    ●   favorite UI widget
    ●   or favorite widget set
●   Expose it to JSF
Don't reinvent a wheel!
●   When you want RichFaces component bend to
    use for your needs...
    ●   Take the component from GitHub
●   Fork the component
    ●   It's just matter of one click with GitHub!
●   Make it work as you need
Publish Your Work
●   Let others
    ●   review it
    ●   find bugs
●   Cooperate with others
    ●   More knowledge
    ●   Get bugs fixed
“And when you want to be part of the successful
community, you can go and open the source!”




 The Open Source Way
         RichFaces Sandbox

      “That's exactly how RichFaces Sandbox works.”
“The community contributions are hosted on the GitHub.
You can reuse them for your needs!”
“RichFaces team is investigating integration
In direction of several of open-source
JavaScript UI widgets.”




                                   Bootstrap




                               “The RichFaces Sandbox is used as part of this effort.”
References
bit.ly/rf-cdk
bit.ly/rf-planet
bit.ly/rf-forums


@RichFaces, #RichFaces, @LFryc


#richfaces – irc.freenode.net
Enjoy the Rich User Experience
THANK YOU!

     @LFRYC
BIT.LY/RF-PLANET
“Photographs used in presentation
have been authored by various authors,
published under Creative Commons license”




 http://www.flickr.com/photos/lonelyplanetexchange/2416006280/
 http://www.flickr.com/photos/davidbolton/4454944721/
 http://www.flickr.com/photos/bjvs/4283146424/
 http://www.flickr.com/photos/egansnow/288478628/
 http://www.flickr.com/photos/negativz/74267002/
 http://www.flickr.com/photos/kyknoord/5333012356/
 http://www.flickr.com/photos/wilhei/109403306/
 http://www.flickr.com/photos/kalmyket/691478431/
 http://www.flickr.com/photos/friarsbalsam/4609210182/
 http://www.flickr.com/photos/paul_lowry/2266388742/
 http://www.flickr.com/photos/breatheindigital/4689159475/
 http://www.flickr.com/photos/eschipul/206714304/

Mais conteúdo relacionado

Mais procurados

Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Gabriel Villa
 
Midgard Create and editing content via RDFa
Midgard Create and editing content via RDFaMidgard Create and editing content via RDFa
Midgard Create and editing content via RDFa
Henri Bergius
 

Mais procurados (20)

Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
Develop a Quick and Dirty Web interface to your database: for the DBA and oth...
 
MEAN Stack
MEAN Stack MEAN Stack
MEAN Stack
 
Web development - Developing Web as A Team
Web development -  Developing Web as A TeamWeb development -  Developing Web as A Team
Web development - Developing Web as A Team
 
Introduction to react native with redux
Introduction to react native with reduxIntroduction to react native with redux
Introduction to react native with redux
 
gwt-pushstate
gwt-pushstategwt-pushstate
gwt-pushstate
 
How to Successfully Implement Headless Drupal
How to Successfully Implement Headless DrupalHow to Successfully Implement Headless Drupal
How to Successfully Implement Headless Drupal
 
Building our App with React Native
Building our App with React NativeBuilding our App with React Native
Building our App with React Native
 
Decoupled Architecture and WordPress
Decoupled Architecture and WordPressDecoupled Architecture and WordPress
Decoupled Architecture and WordPress
 
How To Write Dynamic Migrations - Mohit Aghera
How To Write Dynamic Migrations - Mohit AgheraHow To Write Dynamic Migrations - Mohit Aghera
How To Write Dynamic Migrations - Mohit Aghera
 
Share point saturday presentation 9 29-2012-2
Share point saturday presentation 9 29-2012-2Share point saturday presentation 9 29-2012-2
Share point saturday presentation 9 29-2012-2
 
Shift Remote: JS - Javascript Build Tools: Past & Beyond - Shedrack Akintayo
Shift Remote: JS - Javascript Build Tools: Past & Beyond - Shedrack Akintayo Shift Remote: JS - Javascript Build Tools: Past & Beyond - Shedrack Akintayo
Shift Remote: JS - Javascript Build Tools: Past & Beyond - Shedrack Akintayo
 
Full stack JavaScript - the folly of choice
Full stack JavaScript - the folly of choiceFull stack JavaScript - the folly of choice
Full stack JavaScript - the folly of choice
 
Run Fast, Try Not to Break S**t
Run Fast, Try Not to Break S**tRun Fast, Try Not to Break S**t
Run Fast, Try Not to Break S**t
 
Alloy Framework
Alloy FrameworkAlloy Framework
Alloy Framework
 
Node.js BFFs: our way to better/micro frontends
Node.js BFFs: our way to better/micro frontendsNode.js BFFs: our way to better/micro frontends
Node.js BFFs: our way to better/micro frontends
 
Single Page Applications - Desert Code Camp 2012
Single Page Applications - Desert Code Camp 2012Single Page Applications - Desert Code Camp 2012
Single Page Applications - Desert Code Camp 2012
 
Ionic
IonicIonic
Ionic
 
Rise and Fall of the Frontend Developer
Rise and Fall of the Frontend DeveloperRise and Fall of the Frontend Developer
Rise and Fall of the Frontend Developer
 
Midgard Create and editing content via RDFa
Midgard Create and editing content via RDFaMidgard Create and editing content via RDFa
Midgard Create and editing content via RDFa
 
Adobe Summit 2016 Bombardier’s AEM Implementation for Multi-sites Management
Adobe Summit 2016 Bombardier’s AEM Implementation for Multi-sites ManagementAdobe Summit 2016 Bombardier’s AEM Implementation for Multi-sites Management
Adobe Summit 2016 Bombardier’s AEM Implementation for Multi-sites Management
 

Semelhante a RichFaces CDK: Rapid JSF Component Development

Introduction to ReactJS UI Web Dev .pptx
Introduction to ReactJS UI Web Dev .pptxIntroduction to ReactJS UI Web Dev .pptx
Introduction to ReactJS UI Web Dev .pptx
SHAIKIRFAN715544
 
Javascript spaghetti stirtrek_5_17
Javascript  spaghetti stirtrek_5_17Javascript  spaghetti stirtrek_5_17
Javascript spaghetti stirtrek_5_17
Jared Faris
 
jsf2-composite-components
jsf2-composite-componentsjsf2-composite-components
jsf2-composite-components
Edward Burns
 
React.js - and how it changed our thinking about UI
React.js - and how it changed our thinking about UIReact.js - and how it changed our thinking about UI
React.js - and how it changed our thinking about UI
Marcin Grzywaczewski
 
Reactjs notes.pptx for web development- tutorial and theory
Reactjs  notes.pptx for web development- tutorial and theoryReactjs  notes.pptx for web development- tutorial and theory
Reactjs notes.pptx for web development- tutorial and theory
jobinThomas54
 
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure FunctionsEuropean Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
Sébastien Levert
 

Semelhante a RichFaces CDK: Rapid JSF Component Development (20)

Web Development with Delphi and React - ITDevCon 2016
Web Development with Delphi and React - ITDevCon 2016Web Development with Delphi and React - ITDevCon 2016
Web Development with Delphi and React - ITDevCon 2016
 
Introduction to React JS.pptx
Introduction to React JS.pptxIntroduction to React JS.pptx
Introduction to React JS.pptx
 
Introduction to React native
Introduction to React nativeIntroduction to React native
Introduction to React native
 
Introduction to ReactJS UI Web Dev .pptx
Introduction to ReactJS UI Web Dev .pptxIntroduction to ReactJS UI Web Dev .pptx
Introduction to ReactJS UI Web Dev .pptx
 
Top 7 react developer tools to use in 2021
Top 7 react developer tools to use in 2021Top 7 react developer tools to use in 2021
Top 7 react developer tools to use in 2021
 
Full Stack React Workshop [CSSC x GDSC]
Full Stack React Workshop [CSSC x GDSC]Full Stack React Workshop [CSSC x GDSC]
Full Stack React Workshop [CSSC x GDSC]
 
An evening with React Native
An evening with React NativeAn evening with React Native
An evening with React Native
 
20180518 QNAP Seminar - Introduction to React Native
20180518 QNAP Seminar - Introduction to React Native20180518 QNAP Seminar - Introduction to React Native
20180518 QNAP Seminar - Introduction to React Native
 
Javascript spaghetti stirtrek_5_17
Javascript  spaghetti stirtrek_5_17Javascript  spaghetti stirtrek_5_17
Javascript spaghetti stirtrek_5_17
 
Basic React Knowledge.
Basic React Knowledge.Basic React Knowledge.
Basic React Knowledge.
 
Lezione 03 Introduzione a react
Lezione 03   Introduzione a reactLezione 03   Introduzione a react
Lezione 03 Introduzione a react
 
React.js for Rails Developers
React.js for Rails DevelopersReact.js for Rails Developers
React.js for Rails Developers
 
jsf2-composite-components
jsf2-composite-componentsjsf2-composite-components
jsf2-composite-components
 
React.js - and how it changed our thinking about UI
React.js - and how it changed our thinking about UIReact.js - and how it changed our thinking about UI
React.js - and how it changed our thinking about UI
 
Basic React Knowledge.
Basic React Knowledge.Basic React Knowledge.
Basic React Knowledge.
 
Welcome to React.pptx
Welcome to React.pptxWelcome to React.pptx
Welcome to React.pptx
 
Reactjs notes.pptx for web development- tutorial and theory
Reactjs  notes.pptx for web development- tutorial and theoryReactjs  notes.pptx for web development- tutorial and theory
Reactjs notes.pptx for web development- tutorial and theory
 
Getting Started with React, When You’re an Angular Developer
Getting Started with React, When You’re an Angular DeveloperGetting Started with React, When You’re an Angular Developer
Getting Started with React, When You’re an Angular Developer
 
React - The JavaScript Library for User Interfaces
React - The JavaScript Library for User InterfacesReact - The JavaScript Library for User Interfaces
React - The JavaScript Library for User Interfaces
 
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure FunctionsEuropean Collaboration Summit - SharePoint Framework Angular & Azure Functions
European Collaboration Summit - SharePoint Framework Angular & Azure Functions
 

Mais de Lukáš Fryč

Web Technologies in Java EE 7
Web Technologies in Java EE 7Web Technologies in Java EE 7
Web Technologies in Java EE 7
Lukáš Fryč
 

Mais de Lukáš Fryč (9)

Role of QA in Continuous Delivery
Role of QA in Continuous DeliveryRole of QA in Continuous Delivery
Role of QA in Continuous Delivery
 
Arquillian: Helping web developers and QA get along
Arquillian: Helping web developers and QA get alongArquillian: Helping web developers and QA get along
Arquillian: Helping web developers and QA get along
 
JSF 2.2 Deep Dive with RichFaces 5
JSF 2.2 Deep Dive with RichFaces 5JSF 2.2 Deep Dive with RichFaces 5
JSF 2.2 Deep Dive with RichFaces 5
 
Web Components: Rethinking Web App Development
Web Components: Rethinking Web App DevelopmentWeb Components: Rethinking Web App Development
Web Components: Rethinking Web App Development
 
Web Technologies in Java EE 7
Web Technologies in Java EE 7Web Technologies in Java EE 7
Web Technologies in Java EE 7
 
Designing Top-Class Test Suites for Web Applications
Designing Top-Class Test Suites for Web ApplicationsDesigning Top-Class Test Suites for Web Applications
Designing Top-Class Test Suites for Web Applications
 
Arquillian: Effective tests from the client to the server
Arquillian: Effective tests from the client to the serverArquillian: Effective tests from the client to the server
Arquillian: Effective tests from the client to the server
 
Testing JSF with Arquillian and Selenium
Testing JSF with Arquillian and SeleniumTesting JSF with Arquillian and Selenium
Testing JSF with Arquillian and Selenium
 
RichFaces 4 rolling to Mobile Era
RichFaces 4 rolling to Mobile EraRichFaces 4 rolling to Mobile Era
RichFaces 4 rolling to Mobile Era
 

Último

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Último (20)

The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 

RichFaces CDK: Rapid JSF Component Development

  • 1. Rapid JSF Component Development RichFaces CDK
  • 2. JSF Component Libraries “...are essential part of JSF ecosystem, delivering great user experience”
  • 3. “Components encapsulates complex logic, which is exposed with easy to use interface” Proper Level of Abstraction
  • 4. Building Blocks “Components inter-cooperates in order to build complex application logic.”
  • 5. “But what to do when is same component missing in your favorite component library?”
  • 6. “Fortunately there are many JavaScript widget libraries, which can be simply used just for your needs” Bootstrap
  • 8. “It's very simply to use these widgets, they have as accessible API as JSF components”
  • 9. “It is like going to library and choosing book which best fit in your mood - you can go and reuse JS widget”
  • 11. #1 Direct JavaScript #2 JSF Component #3 JSF Composite Component #4 RichFaces CDK
  • 13. “Imagine big JSF application where you started incorporating JavaScript widgets: looks inconsistent and hardly readable.”
  • 15. “Let's build custom JSF component...”
  • 18. “Tag is representation of the component in the page template code”
  • 19. What is component?  Tag  Component Interface
  • 20. “The component provides interface for changing its configuration” Component
  • 21. “This is source code of JSF component a4j:commandLink”
  • 22. “This is source code of JSF component a4j:commandLink.” “Let's look at the fragment.”
  • 23. “The component is interface with list attributes, Represented as getters/setters of the component class” “Each getter and setter just delegates to StateHelper to keep the state of the component between subsequent requests”
  • 24. What is component?  Tag  Component Interface  Renderer
  • 25. “A renderer is responsible for translating the component to the page representation and then encoding the user input back to the component instance” Component Renderer
  • 26. “A renderer is as verbose as component code, let's look at the sample of h:dataTable component's code”
  • 27. “The renderer uses ResponseWriter to add elements, attributes and text content to the page.” “The Java representation of the renderer is very verbose, which leads to readability and maintainability concerns.”
  • 28. What is component?  Tag  Component interface  Renderer  XML descriptors ● taglib.xml
  • 29. “taglib.xml descriptor is responsible for binding the component from the page template to the component class” Component Renderer
  • 30.
  • 31. What is component?  Tag  Component interface  Renderer  XML descriptors ● taglib.xml ● faces-config.xml
  • 32. “Faces-config.xml registers component into JSF ecosystem” JSF Component Renderer
  • 33.
  • 34. What is component?  Tag  Component interface  Renderer  XML descriptors ● faces-config.xml ● taglib.xml  Documentation
  • 35. “Documentation is necessary for easiness of reuse of the components.”
  • 36. But developing and maintaining all of these informations is not really the way how to develop components in the big scale.
  • 38. Composite Components ● JSF2 feature ● Provides XML representation ● Allowing to write ● HTML directly ● Or compose JSF components ● Developer needs to provide ● Interface ● Implementation
  • 39. Rapid Turnaround ● In the Development stage of the project ● The composite component can be reloaded ● Just with change of the source
  • 41. Immature / Incomplete ● CC have still issues: ● Partial state saving – JAVASERVERFACES-2040 ● AJAX – JAVASERVERFACES-1825 ● Submitted UIInput gets lost – JAVASERVERFACES-1991
  • 42. CC works great for composition of components
  • 43. But they don't replace full-fledged component development
  • 44. Full-Fledged Development?  Tag  XML descriptors ● faces-config.xml ● taglib.xml  Component interface  Renderer  Documentation “So it means we need to get stuck with full-fledged component development?”
  • 45. What we actually need?  Tag  XML descriptors ● faces-config.xml ● taglib.xml  Component interface  Renderer (XML)  Documentation “Let's imagine that the most of the informations are duplicates, which are actually expressed by Component interface”
  • 46. “And at this point, you recognize that some toolkit may be needed to do the job!”
  • 47. “Which is exactly what RichFaces CDK offers!” RichFaces CDK Component Development Kit
  • 48. RichFaces CDK ● Renderer ● XML Templates ● with syntax very close to Composite Components ● Generated in the build-time ● with Convention-over-Configuration in mind
  • 49. But it is build-time tool, right? Is it not too heavy-weight to use in development?
  • 50. Rapid Turnaround ● You can just use your IDE ● And let Java Hot Deployment solutions to do the job ● JRebel works very nice here
  • 51. Resource Development ● But Resources are as needed to develop rapidly as component/renderer code ● JavaScript ● CSS ● Hot Deployment ● using JSF application Development stage
  • 53. Bootstrap “Nothing prevents you to wrap all those libraries!”
  • 55. Let's wrap those widgets!
  • 56. Right level of abstraction ● Let's take ● favorite UI widget ● or favorite widget set ● Expose it to JSF
  • 57. Don't reinvent a wheel! ● When you want RichFaces component bend to use for your needs... ● Take the component from GitHub ● Fork the component ● It's just matter of one click with GitHub! ● Make it work as you need
  • 58. Publish Your Work ● Let others ● review it ● find bugs ● Cooperate with others ● More knowledge ● Get bugs fixed
  • 59. “And when you want to be part of the successful community, you can go and open the source!” The Open Source Way RichFaces Sandbox “That's exactly how RichFaces Sandbox works.”
  • 60. “The community contributions are hosted on the GitHub. You can reuse them for your needs!”
  • 61. “RichFaces team is investigating integration In direction of several of open-source JavaScript UI widgets.” Bootstrap “The RichFaces Sandbox is used as part of this effort.”
  • 63. Enjoy the Rich User Experience
  • 64. THANK YOU! @LFRYC BIT.LY/RF-PLANET
  • 65. “Photographs used in presentation have been authored by various authors, published under Creative Commons license” http://www.flickr.com/photos/lonelyplanetexchange/2416006280/ http://www.flickr.com/photos/davidbolton/4454944721/ http://www.flickr.com/photos/bjvs/4283146424/ http://www.flickr.com/photos/egansnow/288478628/ http://www.flickr.com/photos/negativz/74267002/ http://www.flickr.com/photos/kyknoord/5333012356/ http://www.flickr.com/photos/wilhei/109403306/ http://www.flickr.com/photos/kalmyket/691478431/ http://www.flickr.com/photos/friarsbalsam/4609210182/ http://www.flickr.com/photos/paul_lowry/2266388742/ http://www.flickr.com/photos/breatheindigital/4689159475/ http://www.flickr.com/photos/eschipul/206714304/