From: Robert Klemme Date: 2012-08-28T06:07:07+09:00 Subject: Re: Finding methods inside a scope On Mon, Aug 27, 2012 at 7:37 PM, Dipesh Gtm wrote: > Hmm... > At certain events of my program, I send an email(whose template differs > on what event just happened), update some redis statistics, create and > update some database entries and do some other calculations. I do this > set of actions repetitively for 12-15 events. Do you mean 12-15 different types of events? > I wanted to create a nice > DSL and then keep the actual methods separate from the class which was > turning into a hell of method calls. I was thinking the DSL would serve > as a point of contact, that was what I had in mind. Are users supposed to change the handling of events? > And no, it actually sounds nice to dump the code but I fear I will > somehow be going along the same path again. :-) Maybe we can counsel you to some clarifications of what you are trying to do. I found that lacking clarity is one source for badly structured code. And talking to others - especially from the same field - helps in finding clarity in one's own mind. I can only speak for me of course but I have observed the phenomenon with a few colleagues as well so I reckon it must be generally helpful to communicate about ideas and code. Kind regards robert -- remember.guy do |as, often| as.you_can - without end http://blog.rubybestpractices.com/