struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brandon Goodin" <m...@phase.ws>
Subject RE: FW: ASP.NET - similar to Struts?
Date Wed, 04 Sep 2002 21:24:01 GMT
ted

have you looked at http://www.waferproject.org/index.html

a project to do exactly what you are saying.

-----Original Message-----
From: Ted Husted [mailto:husted@apache.org]
Sent: Wednesday, September 04, 2002 3:16 PM
To: Struts Users Mailing List
Subject: Re: FW: ASP.NET - similar to Struts?


If I understand the question properly, we also consider it good practice
to have the control layer set the values before forwarding to the
presentation page. In Struts, the control layer is most often
represented by the Action. We encourage people to always link to an
Action first before forwarding out to a JSP.

Struts uses ActionForm JavaBeans to carry the values that will populate
the JSP form.

I think it would be interesting to boil down what Struts, ASP.NET, and
the other framework do to generic case studies. I put some preliminary
notes here:

http://husted.com/struts/usecases.html

-Ted.

neal wrote:

> Oops .. in paragraph 3 (QUESTION) ... the last sentence should actually
> read:
>
> Rather, in the ASPX file you would have (a custom tag - aspx:field
name="x"
> />) and then in the *ASPX.CS* file you would set the value of the field:
> form.field(x) = 'xyz'.
>
> -----Original Message-----
> From: neal [mailto:nealcabage@yahoo.com]
> Sent: Wednesday, September 04, 2002 1:23 PM
> To: Struts Users Mailing List
> Subject: ASP.NET - similar to Struts?
>
>
> I noticed a few similarities to ASP.NET in Struts (from a 30,000 foot
> level).  This gave way to a few questions.  I am also curious to know what
> anyone else thinks of this comparison:
>
> BACKGROUND
> In ASP.NET (for those not familiar) there is now seperation of code form
> content, similar to thatr achieved in JSP model 2.  They do it via
> "CodeBehind".  Effectively, every .ASPX file (new ASP extension) comes can
> have a .ASPX.CS compliment file.  This CS (C-sharp) file is effectively
then
> the same thing as the classes written to facilitate the controller for
> various JSPs in an MVC model.
>
> QUESTION
> This got me to thinking....being new to Struts I don't yet know the answer
> to this question, but in ASP.NET it is considered 'good practice' to set
the
> values of the ASP you will forward to, in its compliment ASPX.CS file.
Ok,
> so say that you are editing someone's registration info, the info is
> populated in the form.  You wouldn't use tags to grab the data and set it
> into the form field.  Rather, in the ASPX file you would have (a custom
> tag - aspx:field name="x" />) and then in teh aspx file you would set the
> value of the field: form.field(x) = 'xyz'.
>
> What I am wondering is ... is there a similar mechanism in Struts?  ....
or
> must you pull the values via tag (sort of a pull vs push approach it
> seems)...
>
> Thanks.
> Neal
>
>
> --
> To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
<mailto:struts-user-help@jakarta.apache.org>
>
>


--
Ted Husted, Husted dot Com, Fairport NY US
co-author, Java Web Development with Struts
Order it today:
<http://husted.com/struts/book.html>


--
To unsubscribe, e-mail:
<mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:struts-user-help@jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:struts-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:struts-user-help@jakarta.apache.org>


Mime
View raw message