in general, doing gymnastics to support IS-A syntax when you have a HAS-A semantic is ill-advised.
On Thu, Jan 29, 2009 at 11:54 AM, kropotkin <enquir...@mms-oxford.com> wrote: > > Hi > > In general is it better to use a class method or object method? E.g I have a > class A which provides certain functionality. I just want to use one of its > methods in another class B. Is it better to inistantiate class A and do and > object call or just do A->myMethod() ? The method doesn't need a reference > to itself passed in so from that point of view it doesn't matter > > Thanks > > Justin but that isn't what you're asking, is it. If the method supports it, I'd go with the class method, or even a direct call to it by name if I know it isn't inherited: A::myMethod() -- "The only thing that separates us from the animals is tattoos" -- Drea Smith