Dear All,

Can somebody explain me how to correctly set a new class-specific method
for generic functions (e.g. for "plot", "summary" and "print"). I simply
programmed these functions with the class names and it works perfectly.
E.g.:

x<-2
y<-3
class(x)<-"newclass"
class(y)<-"newclass"
print.newclass<-function(x){ cat(x*10) }
print(x)
print(y)

However, I need the new methods for a new package, and the "R CMD check"
gives me warnings that my approach is not correct. I have to define methods
and do not use full names as "print.newclass".
I read the "Writing R Extensions" and it is not explained there (at least
to such level that I can get it) and didn't get anything understandable by
googling.

Many thanks in advance!
Mikhail

	[[alternative HTML version deleted]]

