From: Robert Dober Date: 2007-05-31T06:26:13+09:00 Subject: Re: #respond_to? not working for dynamically generated methods On 5/30/07, Wolfgang N�dasi-Donner wrote: > James Edward Gray II schrieb: > > What exactly is the use case for respond_to?()? > > Only as a remark for a special usage, which is not easy (impossible?) without > "respond_to?()". > > I have some Libraries for textual analysis, which are usually used via "irb". > The application works on large Arrays of String objects. Based on regular > expressions I define sometimes methods for some of these object, during one > textual analysis often several methods. > > Then I can categorize the String objects in the Array by using "respond_to?()". > > It is very easy and helpful (may be it sounds complex an strange, but this is > only my bad English). Hmm as fellow native German Speaker I think your English is perfect. Could you give an example? I somehow feel that you might use a different approach than hitchhiking methods, or are the used for different purposes too. Sounds interesting. Cheers Robert -- You see things; and you say Why? But I dream things that never were; and I say Why not? -- George Bernard Shaw