db-torque-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Della Bitta <mdellabit...@earthlink.net>
Subject Re: can torque generate protected methods for getters?
Date Mon, 01 Dec 2003 04:17:03 GMT
this might not be what you want to hear, but maybe your Torque objects 
shouldn't be available in your JSP at all if this is an issue... take a 
look at the Data Transfer Object pattern.

Michael

On Nov 30, 2003, at 7:15 PM, Caoilte O'Connor wrote:

> Hi,
> Members of my development team have got lazy and started
> using the foreign key getters from torque objects widely in
> jsp pages. That could end up being a lot of database hits
> so I would like to prevent (not just disencourage) them
> from doing this.
>
> Is there anyway to make only simple getter/setter methods
> public and to make all other foreign key getter / complex
> joins etc protected so that I can encapsulate them in
> proper business logic that hits the db only once.
>
> I've had another look at the properties file and can't see
> anything relevent.
>
> can anyone offer any advice?
>
> c
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
> For additional commands, e-mail: torque-user-help@db.apache.org
>


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


Mime
View raw message