You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@velocity.apache.org by ma...@cmklein.de on 2005/06/18 04:09:54 UTC

Velocity vs. JSF

After looking at both Velocity and JSF, I am wondering if there is still a
reason to use Velocity instead of JSF.

In other words: Is JSF about to replace Velocity or in what cases is
Velocity 'better' than JSF?

Thanks

Matt

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


Re: Velocity vs. JSF

Posted by Daniel Dekany <dd...@freemail.hu>.
Sunday, June 19, 2005, 4:39:45 PM, Nathan Bubna wrote:

> eh, i haven't spent much time looking at JSF yet, but Craig McClanahan
> has always given me the impression that you can use the Velocity as a
> renderer for JSF if you want (JSF+Velocity vs. JSF+JSP) and that
> neither can really replace or exclude the other.
[snip]

The point of JSF is that you can use "RAD tools" for placing and
configuring the GUI components on the page. For that of course serious
IDE support is needed. There are IDE-s for JSP+JSF, but for
Velocity+JSF? Without that JSF is pointless, isn't it?

-- 
Best regards,
 Daniel Dekany


---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


Re: Velocity vs. JSF

Posted by Nathan Bubna <nb...@gmail.com>.
On 6/19/05, Matthias Klein <ma...@cmklein.de> wrote:
> Thanks for that answer.
> 
> Based on that, let me ask a bit more specific:
> Let's say you need to describe a web based UI in a flexible way where
> - one part describes the design/layout (colors, fonts, where things are
> placed...)

CSS

> - one part describes the navigation within that page (menu, buttons...)

you can use #parse( "Menu.vm" ) or something more powerful like the
VelocityLayoutServlet
(http://jakarta.apache.org/velocity/tools/view/layoutservlet.html)

> - one part describes the dynamic content (the 'real' content that you
> actually want to show to your customer)

if using the VelocityLayoutServlet, then this is your "Screen".

> How can do you do that?
> 
> The important thing is that a designer should only work on the first part,
> thereby defining design templates that can be applied to several web GUIs. I
> assume, this piece could be done with XHTML & CSS. Or are there other
> standards?

CSS is works fine with either HTML or XHTML.

> But for the last 2 pieces I am not sure.
> 
> I know that portals such as intrexx or exo use both Velocity and JSF. But at
> least intrexx seems to have a higher abstraction layer through which they
> describe their GUI.
> 
> At first I thought that can be done with Velocity but now I am not that sure
> anymore because Velocity requires to embed a lot of VTL into HTML which is
> not exactly helping when you need to separate the design aspect from the
> content aspect.

eh, i know this is probably a religious debate, but i consider all
HTML to be part of the design aspect.  therefore, allowing designers
to do VTL & HTML (which is easy to learn) *is* separating the design
from the content.  also note that Velocity makes no requirements about
how much VTL you use in a template; use as little or much as you like.
:)

> Any suggestions?
> 
> Thanks
> 
> Matt
> 
> 
> 
> 
> > -----Ursprüngliche Nachricht-----
> > Von: Nathan Bubna [mailto:nbubna@gmail.com]
> > Gesendet: Sonntag, 19. Juni 2005 11:40
> > An: Velocity Users List
> > Betreff: Re: Velocity vs. JSF
> >
> >
> > eh, i haven't spent much time looking at JSF yet, but Craig
> > McClanahan has always given me the impression that you can
> > use the Velocity as a renderer for JSF if you want
> > (JSF+Velocity vs. JSF+JSP) and that neither can really
> > replace or exclude the other.
> >
> > as for cases that Velocity is "better", i think those would
> > be the things for which Velocity is designed.  JSF is not
> > meant to be a generic templating language/tool; Velocity is.
> > you don't use Velocity to handle UI events or whatnot,
> > neither will you begin using JSF to generate emails or code
> > or sql or whatever you want from a template.
> >
> > the usual "apples and oranges" cliche seems very appropriate here. :)
> >
> > On 6/17/05, matthias@cmklein.de <ma...@cmklein.de> wrote:
> > > After looking at both Velocity and JSF, I am wondering if there is
> > > still a reason to use Velocity instead of JSF.
> > >
> > > In other words: Is JSF about to replace Velocity or in what
> > cases is
> > > Velocity 'better' than JSF?
> > >
> > > Thanks
> > >
> > > Matt
> > >
> > >
> > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> > > For additional commands, e-mail:
> > velocity-user-help@jakarta.apache.org
> > >
> > >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


AW: Velocity vs. JSF

Posted by Matthias Klein <ma...@cmklein.de>.
Thanks for that answer.

Based on that, let me ask a bit more specific:
Let's say you need to describe a web based UI in a flexible way where 
- one part describes the design/layout (colors, fonts, where things are
placed...)
- one part describes the navigation within that page (menu, buttons...)
- one part describes the dynamic content (the 'real' content that you
actually want to show to your customer)

How can do you do that? 

The important thing is that a designer should only work on the first part,
thereby defining design templates that can be applied to several web GUIs. I
assume, this piece could be done with XHTML & CSS. Or are there other
standards?

But for the last 2 pieces I am not sure.

I know that portals such as intrexx or exo use both Velocity and JSF. But at
least intrexx seems to have a higher abstraction layer through which they
describe their GUI.

At first I thought that can be done with Velocity but now I am not that sure
anymore because Velocity requires to embed a lot of VTL into HTML which is
not exactly helping when you need to separate the design aspect from the
content aspect.

Any suggestions?

Thanks

Matt




> -----Ursprüngliche Nachricht-----
> Von: Nathan Bubna [mailto:nbubna@gmail.com] 
> Gesendet: Sonntag, 19. Juni 2005 11:40
> An: Velocity Users List
> Betreff: Re: Velocity vs. JSF
> 
> 
> eh, i haven't spent much time looking at JSF yet, but Craig 
> McClanahan has always given me the impression that you can 
> use the Velocity as a renderer for JSF if you want 
> (JSF+Velocity vs. JSF+JSP) and that neither can really 
> replace or exclude the other.
> 
> as for cases that Velocity is "better", i think those would 
> be the things for which Velocity is designed.  JSF is not 
> meant to be a generic templating language/tool; Velocity is.  
> you don't use Velocity to handle UI events or whatnot, 
> neither will you begin using JSF to generate emails or code 
> or sql or whatever you want from a template.
> 
> the usual "apples and oranges" cliche seems very appropriate here. :)
> 
> On 6/17/05, matthias@cmklein.de <ma...@cmklein.de> wrote:
> > After looking at both Velocity and JSF, I am wondering if there is 
> > still a reason to use Velocity instead of JSF.
> > 
> > In other words: Is JSF about to replace Velocity or in what 
> cases is 
> > Velocity 'better' than JSF?
> > 
> > Thanks
> > 
> > Matt
> > 
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: 
> velocity-user-help@jakarta.apache.org
> > 
> >
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


Re: Velocity vs. JSF

Posted by Nathan Bubna <nb...@gmail.com>.
eh, i haven't spent much time looking at JSF yet, but Craig McClanahan
has always given me the impression that you can use the Velocity as a
renderer for JSF if you want (JSF+Velocity vs. JSF+JSP) and that
neither can really replace or exclude the other.

as for cases that Velocity is "better", i think those would be the
things for which Velocity is designed.  JSF is not meant to be a
generic templating language/tool; Velocity is.  you don't use Velocity
to handle UI events or whatnot, neither will you begin using JSF to
generate emails or code or sql or whatever you want from a template.

the usual "apples and oranges" cliche seems very appropriate here. :)

On 6/17/05, matthias@cmklein.de <ma...@cmklein.de> wrote:
> After looking at both Velocity and JSF, I am wondering if there is still a
> reason to use Velocity instead of JSF.
> 
> In other words: Is JSF about to replace Velocity or in what cases is
> Velocity 'better' than JSF?
> 
> Thanks
> 
> Matt
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org