Re: Annouce: DBIx::Class, a.k.a "taking the easy way out"

[prev] [thread] [next] [Date index for 2005/07/26]

From: Tony Bowden
Subject: Re: Annouce: DBIx::Class, a.k.a "taking the easy way out"
Date: 23:14 on 26 Jul 2005
On Wed, Jul 27, 2005 at 12:13:40AM +0100, Matt S Trout wrote:
> > > Plus, what if you want to plug-and-play with layers of search generation?
> > > My::Search does the WHERE condition
> > > My::OrderBy adds the ORDER BY
> > > My::Limit add the LIMIT clause
> > All the plugins need to know is what they can do with the searcher,
> > based on on what's in its API. 
> What happens if each one needs to interrupt the search process at a different
> stage, and some need to interpose themselves to figure out the results?

You've just changed the focus of the discussion quite dramatically.

The code posted was about generating the search, not in executing it.

Can you give some new examples of what sorts of things you're talking
about here?

> e.g. you have Pre, Wrap1, Wrap2, Post
> Your calling order goes
> Pre { }
> Wrap1 {
>   Wrap2 {
>     Original
>   }
> }
> Post { }
> By the time you've added enough delegation hooks to make the whole thing
> work, I'd expect you'd end up with an API that's overcomplicated, higher
> overhead than my approach and there's probably still a fairly good chance
> of a plugin author breaking stuff if they're not careful.

Straw man.

No-one has postulated the code you're suggesting, so tearing that down
is no real value.

Tony

(message missing)

Re: Annouce: DBIx::Class, a.k.a "taking the easy way out"
Tony Bowden 23:14 on 26 Jul 2005

Delegation vs Hooks (was: Annouce: DBIx::Class, a.k.a "taking the easy way out")
=?ISO-8859-1?Q?Ask_Bj=F8rn_Hansen?= 23:27 on 26 Jul 2005

Generated at 16:37 on 28 Jul 2005 by mariachi v0.52