Content deleted Content added
No edit summary |
|||
Line 1:
'''Java view technologies and frameworks
Java view-layer frameworks often claim to support some or all of the [[Model–view–controller]] design pattern.
==At a glance==
{| class="wikitable" border="1"
|-
! Action-based frameworks:
| [[Apache Struts]], [[Spring Framework|Spring MVC]]
|-
! Component-based frameworks:
| [[Apache Click]], [[Apache Tapestry]], [[Apache Wicket]], [[JavaServer Faces]]
|-
! Web template systems:
| [[Apache Tiles]], [[SiteMesh]], [[Thymeleaf]]
|-
|}
* [[JavaServer Faces]] (JSF), [[Apache Tapestry]] and [[Apache Wicket]] are competing component-based technologies, abstracting the [[Stateless protocol|stateless]] HTTP request-response cycle and the [[Java Servlet API]] behind an [[Object-oriented programming|object-oriented]], event-driven component model.
* In contrast, Struts and the [[Spring Framework]] are action-oriented frameworks that provide a thinner [[abstraction layer]] over the servlet [[API]].
* Apache Tiles is a templating framework designed to work with Struts.
* [[Facelets]] is a view definition and templating technology designed to work with JSF.
* [[SiteMesh]] can be used with any [[JavaServer Pages|JSP]].
* Facelets, Tapestry and Wicket have their own templating approaches based on [[HTML]]/[[XHTML]].
* [[Apache Click]] uses HTML based [[Apache Velocity]] templates and [[Plain Old Java Object]]s, with [[JavaServer Pages]] optional.
==Servlet API==
Line 29 ⟶ 51:
In this Java jGrasp Training Course we will see an introduction to this development environment used to write Java programs. We will see over the course classes, how to create them, what they contain, and how to create objects in the main method. We will also discuss constructors, getters and setters, and...
==Apache Wicket==
Line 39 ⟶ 60:
* Web page components are 'pushed' into the HTML markup from the code.
* '''Competitor''': Tapestry, JSF, HybridJava
==JavaServer Faces (JSF) and Facelets==
* A specification for component-based view frameworks.
* Mojarra and Apache MyFaces implementations are available
* Typically uses Facelets for XML/XHTML-based templating.
* Classes are written as POJOs, with and Annotations or XML configuration files used to associate them with page and component templates.
* The [[Unified Expression Language]] allows binding component fields and events to POJO bean properties and methods.
* Conversion and validation constraints can be specified in Facelets and are automatically applied, normally resulting in reposting of the same page with error information in case of failure.
* Navigation can be via configuration file rules or directly specified in the page.
* Can transparently support [[Ajax (programming)|Ajax]].
* '''Competitor''': Wicket, Tapestry
==SiteMesh==
|