views:

49

answers:

3

-Given a series of x number (unknown) steps,

-all of which implement the same interface,

-and where the order of the steps is desired to be configurable,

can anyone suggest a good design pattern?

+3  A: 

Chain of Responsibliity

Generally 1 person handles the chain, but its not to say that multiple things couldn't handle the request.

Nix
Related question: It seems to me that the pattern violates SRP. Is there any reason why the chaining might not be implemented outside of the steps?
macke
A: 

Command and/or Decorator

SWeko
A: 

Chain of responsibility is the usual candidate for this sort of thing, coupled with some variation on the inversion of control theme for initial construction of the chain according to the "configured" sequence.

Nicole Calinoiu