You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by suhas <su...@techmas.hcltech.com> on 2001/07/27 13:40:20 UTC
some comparision between JSP/struts and velocity
http://jakarta.apache.org/velocity/ymtd/ymtd-taglibs.html
Suhas
Re: some comparision between JSP/struts and velocity
Posted by Oleg V Alexeev <oa...@apache.org>.
Hello suhas,
Friday, July 27, 2001, 3:40:20 PM, you wrote:
s> http://jakarta.apache.org/velocity/ymtd/ymtd-taglibs.html
8) Author of this article take a wrong way to compose struts sample...
He (Jon S. Stevens) place a container creation code to the JSP page -
yes, such approach not so fine for any application, not only struts
based. Struts main approach is to create all business objects in
Action class and forward to the JSP view. It is MVC2, not MVC.
--
Best regards,
Oleg mailto:oalexeev@apache.org
RE: some comparision between JSP/struts and velocity
Posted by Greg Maletic <gr...@ZeroG.com>.
This article contains an assertion that goes unquestioned in a lot of the
documentation for templating engines, but it's one that seems incorrect to
me. After showing an example of some HTML code that contains both Struts
tags and a Java scriptlet, the author says:
It is clear from the Struts example above that the whole strict MVC model
has been broken again because a call to java.util.ArrayList and creating an
Object is embedding Java code within a template.
To my way of thinking, MVC isn't broken by simply putting Java code into an
HTML page. Putting business logic into the HTML page (view) breaks MVC, but
the presence of Java code--if used only to support the view--does not.
Similarly, I'd argue that it's possible to break MVC even using tags, if the
tag implements business logic. (And what is a tag, after all, besides Java
code?)
Do other people agree?
======================================
Greg Maletic
Chief Technical Officer
Zero G Software, Inc.
514 Bryant Street
San Francisco, CA 94107
tel: +1.415.512.7771 x303
fax: +1.415.723.7244
mailto:greg@ZeroG.com
http://www.ZeroG.com
The leading provider of multi-platform software deployment solutions.
======================================
-----Original Message-----
From: struts-user-return-14160-greg.maletic=zerog.com@jakarta.apache.org
[mailto:struts-user-return-14160-greg.maletic=zerog.com@jakarta.apache.org]O
n Behalf Of suhas
Sent: Friday, July 27, 2001 4:40 AM
To: struts-user@jakarta.apache.org
Subject: some comparision between JSP/struts and velocity
http://jakarta.apache.org/velocity/ymtd/ymtd-taglibs.html
Suhas