struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andrew Hill" <andrew.david.h...@gridnode.com>
Subject RE: DAO or ... ?
Date Mon, 14 Oct 2002 14:56:35 GMT
So where should one invoke the persistance layer?

-----Original Message-----
From: Lacerda, Wellington (AFIS) [mailto:Wellington.Lacerda@fao.org]
Sent: Monday, October 14, 2002 22:51
To: 'Struts Users Mailing List'
Subject: RE: DAO or ... ?
Importance: High


Hi Kevin

Avoid persistence in Action code as much as you can.

This is the general recommendation.

Wellington Silva
Author of "JSP and Tag Libraries for Web Development"
FAO of the UN - Consultant

-----Original Message-----
From: Kevin Viet [mailto:vietk@activia.net]
Sent: Monday, October 14, 2002 4:45 PM
To: struts-user
Subject: DAO or ... ?


My question is a web app design question.
What pattern you guys follow when you want to save a domain object in
the database ?:

- use the DAO pattern of java blueprint  (persistence layer is called
into classes)
- call to persistence statements into action code :

	// store example
	try {
		PeristenceLayer pl = getPerstitenceLayer();
		pl.save(domainObject);
	}
	catch (Exception


--
Kevin Viet <vietk@activia.net>
ActiVia Networks




--
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>


--
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