Re: The wisdom of the object mentors (Was: Searching OO Associations with RDBMS Persistence Models)
From: Marshall <marshall.spight_at_gmail.com>
Date: 4 Jun 2006 20:52:22 -0700
Message-ID: <1149479542.784502.13110_at_j55g2000cwa.googlegroups.com>
Date: 4 Jun 2006 20:52:22 -0700
Message-ID: <1149479542.784502.13110_at_j55g2000cwa.googlegroups.com>
Phlip wrote:
> Marshall wrote:
>
> > So every time you need to do any query, you just mechanically wrap it
> > in a method? Then the use of these wrapper methods is okay anywhere
> > in the application that needs to make them?
>
> When those techniques relieve duplication.
>
> Suppose 12 of my modules bulldoze the BULLDOZE table. Gee, maybe I should
> wrap that up in a Bulldoze object and hide all the SQL statements inside
> that.
>
> Now suppose one little module reads the CONFIG table at startup. Screw it;
> just hard-code a SELECT statement and don't look back.
>
> The goal is to replace duplicated statements with better design.
Works for me.
Marshall Received on Mon Jun 05 2006 - 05:52:22 CEST