Hi,

I'm having trouble seeing the added value over functions defined by setGeneric 
vis-a-vis
methods defined by inheritance and polymorphism. setGeneric offers a 'clean' 
call to a generic function, ie. no need to call new(), so less typing to do for 
the user. But such explicit calls can also be avoided by functions like f <- 
function(x, y) new(Class = SomeClass, x=x, y=y). Then again, R relies heavily 
on method dispatching, so it must have clear advantages.

*confused* Can anybody enlighten me? Thanks in advance!

Cheers!!
Albert-Jan

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
All right, but apart from the sanitation, the medicine, education, wine, public 
order, irrigation, roads, a fresh water system, and public health, what have 
the Romans ever done for us?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


      
        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to