Re: The Right Level of Patterns
- From: "John Gagon" <john.gagon@xxxxxxxxx>
- Date: 17 Jul 2006 17:02:01 -0700
Chris Uppal wrote:
John Gagon wrote:
The observer has so many synonymns in the real world that it is the
simplest and most confusing at the same time. But it is one I've really
started to fall in love with and has almost become a golden hammer of
sorts. It has been most appropriate for my latest project.
Observer is almost as generic as "Function call" -- a design pattern that has
to be implemented by hand in some languages, but is so very useful that it is
built in to most current general-purpose languages.
Inversion of control seems it could almost be like that too. You're
right and I do pretty much think of "Observer" that way...that is as a
"function call" but a reregistered/passive/inverted (?) one perhaps. It
gives real world "control" instead of a system forced control, meaning,
it adapts to the real world. Event driven programming and the
constructs are common in other languages. I've read articles about how
it might, in ways, compete with threading. Threading seems most
appropriate in this new "multicore" advantage trend.
Another extra-ordinarily wide ranging design pattern -- so general that it's
hard to think of it as a pattern at all[*] -- is "Extra Level of Indirection".
I'm assuming this is aka Delegate or "Wrapper". *laughs* I agree. I
think it's like you say with java, there are no "built in constructs"
for things common in other languages. (ie: LISP macros etc etc). The
only reason the patterns exist at all perhaps is because of multiple
"types" filling various "common roles".
([*] But experienced practitioners do recognise it, and know it as an old
friend to be trotted out as the solution to all sorts of thorny design
problems.)
Yep.
Aside note without further addressing the OP here, a few anti-patterns
I find are useful conversationally but I find they may have more to do
with strategy than an implementation tactic other than say "spaghetti".
Does anyone own that book? I had talked about it so much without
actually owning a book that not long ago, I acquired it just for that
reason.
I find that I have a copy on my shelves (assuming you mean the book
"Anti-patterns"); I cannot for the life of me remember whether I have ever
actually read it...
-- chris
I find too the books on my shelves don't get an end to end reading. Not
even this one yet but it's nice to have and perhaps I'll use it someday
again since it's generic. A whole lot better than the fluffy "Java
Bible" I once got a long time ago. Horrid horrid book.
.
- References:
- The Right Level of Patterns
- From: dan . fanelli
- Re: The Right Level of Patterns
- From: Chris Uppal
- Re: The Right Level of Patterns
- From: John Gagon
- Re: The Right Level of Patterns
- From: Chris Uppal
- The Right Level of Patterns
- Prev by Date: Re: what's better way to store a million keys in mem?
- Next by Date: Re: How Do You Tell How Long it Takes for a Piece of Code to Execute?
- Previous by thread: Re: The Right Level of Patterns
- Next by thread: Re: The Right Level of Patterns
- Index(es):
Relevant Pages
|