Skip to Content.
Sympa Menu

patterns-discussion - Re: [patterns-discussion] Pattern Selection Question

patterns-discussion AT lists.cs.illinois.edu

Subject: General talk about software patterns

List archive

Re: [patterns-discussion] Pattern Selection Question


Chronological Thread 
  • From: Komtanoo Pinpimai <romerun AT gmail.com>
  • To: patterns-discussion AT cs.uiuc.edu
  • Subject: Re: [patterns-discussion] Pattern Selection Question
  • Date: Tue, 4 Oct 2005 11:04:11 -0500
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=rHYj4MSsNk/1VJ0VhN7cQ1ud8+/A6J3HvOYkT+Q4Se36bx2e37JAfibM4Z/gePnX0mXin0d+UNzT7aHvP8z/huNvxdbrWrmkXWSJA4W6mNXqixFjrSc44I70DPwF7zYv9UExoQ1H9S1rMRCEzaZ+I7ou3378UPyVl0iGXHtAaU4=
  • List-archive: <http://lists.cs.uiuc.edu/pipermail/patterns-discussion>
  • List-id: General talk about software patterns <patterns-discussion.cs.uiuc.edu>

If some errors occur in a responsibility, it means the raw message is
invalid, the responsibility can return null protocol object and the
outmost control flow just discards it. It seems like the topic owner
tried to approach this message parsing step by state pattern, but I
think it should be chain of res. instead.

In addition, in case that each protocols are quite different to parse,
it might need to introduce some strategy patterns into the model.

-thanks
kem

On 10/4/05,
jdeena AT comcast.net

<jdeena AT comcast.net>
wrote:
>
> What about the builder with partial build information (or the startgey that
> owns the builder) if there is an error between the chains of responsibilty
> and returns immediatly.
> Curious to know..
> Regards
> Deena
>
> -------------- Original message --------------
>
> > aYeah, I've just come up with an idea to use chain of responsibility
> > together with builder. The first responsibility is to parse header,
> > extract message length and protocol information, and insert these
> > information into a builder, then cll the second responsibility to
> > parse body, add it to the builder and so on.. in each responsibility,
> > if it detects error, it won't call the next responsibility, but return
> > immediately. The last responsibility will generate protocol object
> > from the builder.
> >
> > -thanks
> > kem.
> >





Archive powered by MHonArc 2.6.16.

Top of Page