Struts is JSP and Tag centric and with a fixed dependecy on
being deployed in a conventional Servlet HTTP request /
response environment.
JSF is somewhat more generic. It is component centric and
has no specific dependency on HTML markup / tags apart from
the fact that the renders for most components are tailored
for conventional browser output via HTML.
both will implement mvc2 design pattern,and struts given by
apache ,jsf given by sun,instead of actionservlet we can
find facelet asa acontroller in jsf
Both will implement mvc2 design pattern, struts given by
apache, jsf given by sun.
Struts didn't provide any use implementations but JSF we
can implement our own implementations like UI-components,
JSF provides the Converters also
The main difference is the UIComponent of JSF. Developers
can define their own components and also the way it should
be rendered. A component having a particular behavious can
be rendered in different ways.
Eg: UISelectOne. This components behaviour is to select one
value, but can be rendered as a List, Menu or Radio.
More we can develop RenderKit's appropriate to the client,
ie html, wml, etc. So a single JSF application can be used,
and using different renderers can be rendered to different
clients...
Jsf is component based frame work which concentrates on
UIComponents look and feel(view layer) where as struts
concentrates more on the controller part not on the
userinterface but both follow model-2 architecture
Configuration wise both are same and supports the
internalization. JSF is more developer friendly why because
to validate mandatory filed in JSF we can specify attribute
like require is true and we can use mandatory filed id in
message tag. But in struts we have to include
validation-rules.xml in struts-config.xml and form has to be
specified in validation-rules.xml.
Even for condition statement in JSF is better than struts.
No need to overwrite any method like execute in JSF.
Struts is a "Component" Framework, whereas Struts is
an "action" Framework.
JSF using Navigationcase and NavigationRules instead of
Actionmapping and action which is in Struts.
Struts framework give you the ability to map URLs to
activities and code on the back end, whereas JSF rendered
on the page are initially developed as individual
components, much like in modern GUI.
jsf is a component framework which concentrates on view
componets creation,binding and rendering where as struts is
a action frame work which concentrates on creating and
calling the action methods
i have list of values(e.g 100).
using logic:iterate, how can i print the multiples of 5th
element?
how the logic:iterate will understand the multiples of 5.