Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.help > #561

Re: Related containers

From markspace <-@.>
Newsgroups comp.lang.java.help
Subject Re: Related containers
Date 2011-04-06 11:44 -0700
Organization A noiseless patient Spider
Message-ID <inicba$gnr$1@dont-email.me> (permalink)
References <7a589c9f-8b85-4000-ba05-ab67ecdd8b0a@o26g2000vby.googlegroups.com>

Show all headers | View raw


On 4/6/2011 10:58 AM, Rob McDonald wrote:

> Is there a design pattern which relates to this situation?  Is there a
> suggested or canonical solution?


I'm not sure what you are doing, but it seems you want to execute a 
hierarchy of things.  That sounds like an Interpreter:

http://en.wikipedia.org/wiki/Interpreter_pattern

Here, your Task would be a TerminalExpression, and your GroupTask would 
be a NonTerminalExpression.  Otherwise, the Interpreter pattern seems 
much simpler.  It's at least worth a look.


Back to comp.lang.java.help | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Related containers Rob McDonald <rob.a.mcdonald@gmail.com> - 2011-04-06 10:58 -0700
  Re: Related containers markspace <-@.> - 2011-04-06 11:44 -0700
  Re: Related containers Roedy Green <see_website@mindprod.com.invalid> - 2011-04-06 12:50 -0700

csiph-web