RE: Forms Beans and DAO (Best Practices)

2002-05-13 Thread Trieu, Danny
, May 11, 2002 2:09 PM To: Struts Users Mailing List Subject: Re: Forms Beans and DAO (Best Practices) may want to hold stuff that is not Strings, in the form and not the dvo, because it may be in an invalid format... sandeep --- stuart robertson [EMAIL PROTECTED] wrote: Another

Re: Forms Beans and DAO (Best Practices)

2002-05-11 Thread Sandeep Takhar
may want to hold stuff that is not Strings, in the form and not the dvo, because it may be in an invalid format... sandeep --- stuart robertson [EMAIL PROTECTED] wrote: Another approach to this is to have the form beans simply hold references to the value objects (from the DAO) directly.

Re: Forms Beans and DAO (Best Practices)

2002-05-06 Thread stuart robertson
Another approach to this is to have the form beans simply hold references to the value objects (from the DAO) directly. You can use the nested taglibraries that are now a part of struts 1.1 to access these when building html forms. The slick thing is that when the servlet populates the form

Re: Forms Beans and DAO (Best Practices)

2002-05-04 Thread @Basebeans.com
Subject: Re: Forms Beans and DAO (Best Practices) From: Vic Cekvenich [EMAIL PROTECTED] === (great thread) If #1 is prefered, can somone please coment as to the practical value of the valueObject layer if one is not doing EJB. Why not: myFormBean.setDAO(myDAO.retSelf()); This allows me

Re: Forms Beans and DAO (Best Practices)

2002-05-04 Thread @Basebeans.com
Subject: Re: Forms Beans and DAO (Best Practices) From: Vic Cekvenich [EMAIL PROTECTED] === My example is on the home page and on downloads and it has full working code I teach Struts from(ok not the latest version, I have to $ave something for the class), and so is all the source code. Ans

Re: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Kevin . Bedell
I see what you're doing and agree it seems easier. But coupling the form beans to the DAO's so tightly I wouldn't call a best practice. Here is another approach: - Have the DAO's return Value Objects. But then have a setValueObject() on the form bean so you can store the entire value object

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Chen, Dean (Zhun)
Mailing List Subject: Re: Forms Beans and DAO (Best Practices) I see what you're doing and agree it seems easier. But coupling the form beans to the DAO's so tightly I wouldn't call a best practice. Here is another approach: - Have the DAO's return Value Objects. But then have a setValueObject

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Pruthee, Ranjan
to actual EJBs and nothing in the web tier has to change and both DAOs and DTOs can be reused. -Original Message- From: Chen, Dean (Zhun) [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 2:23 PM To: 'Struts Users Mailing List' Subject: RE: Forms Beans and DAO (Best Practices

Re: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Graham Lounder
, 2002 4:25 PM Subject: RE: Forms Beans and DAO (Best Practices) In general, I use the Struts action classes as proxies to my business objects and my business objects serve as proxies to my data access objects and I pass data across tiers using DTO (DataTransportObject [use to be ValueObject

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Kevin . Bedell
: RE: Forms Beans and DAO (Best Practices) In general, I use the Struts action classes as proxies to my business objects and my business objects serve as proxies to my data access objects and I pass data across tiers using DTO (DataTransportObject [use to be ValueObject]). In this fashion, I can

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Pruthee, Ranjan
!! -Ranjan. -Original Message- From: Graham Lounder [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 2:35 PM To: Struts Users Mailing List Subject: Re: Forms Beans and DAO (Best Practices) This is a really good description. I do have one small question, where does the connection pooling

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Jayaraman Dorai
- From: Pruthee, Ranjan [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 3:25 PM To: Struts Users Mailing List Subject: RE: Forms Beans and DAO (Best Practices) In general, I use the Struts action classes as proxies to my business objects and my business objects serve as proxies to my

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Pruthee, Ranjan
it will be a heavyweight component will lot of dependencies. Reuse will take hit with this approach but that just me. Ranjan. -Original Message- From: Jayaraman Dorai [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 3:07 PM To: Struts Users Mailing List Subject: RE: Forms Beans and DAO (Best Practices

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Jayaraman Dorai
Subject: RE: Forms Beans and DAO (Best Practices) The way I do it is - BO -- DAO ---returns the recordset and not ValueObject. This RS is passed back to the BO. which passes it to the ValueObject to build it. The code will look something like this - public class BO { CustomerVO custvo = new

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Pruthee, Ranjan
:54 PM To: Struts Users Mailing List Subject: RE: Forms Beans and DAO (Best Practices) How do you create a customer. (i.e.) Add a new record in the database from the data entered in the HTML client. The way I currently do is 1. The action form has the Value Object 2. The action class gets

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Mike Duffy
of dependencies. Reuse will take hit with this approach but that just me. Ranjan. -Original Message- From: Jayaraman Dorai [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 3:07 PM To: Struts Users Mailing List Subject: RE: Forms Beans and DAO (Best Practices) I use it the same way

RE: Forms Beans and DAO (Best Practices)

2002-05-03 Thread Robert Taylor
-Original Message- From: Mike Duffy [mailto:[EMAIL PROTECTED]] Sent: Friday, May 03, 2002 6:20 PM To: Struts Users Mailing List Subject: RE: Forms Beans and DAO (Best Practices) Ranjan, Thank you for your insightful comments. Isn't it more likely that you would want to isolate