Rev 16802 | Rev 24055 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed
\name{representation}\alias{representation}\title{ Describe A Class Representation }\description{Constructs a description of a class (without verifying the validity ofthe description). A convenience function in calls to\code{\link{setClass}}.}\usage{representation(...)}\arguments{\item{...}{The call to representation takes arguments that are single characterstrings. Unnamed arguments are classes that a newly defined classextends; named arguments name the explicit slots in the new class,and specify what class each slot should have.}}\details{The \code{representation} function applies tests for the validity ofthe arguments. Each must specify the name of a class.The classes named don't have to exist when \code{representation} iscalled, but if they do, then the function will check for any duplicateslot names introduced by each of the inherited classes.}\value{The value is just the list of arguments, after these have been checkedfor validity.}\references{The web page \url{http://www.omegahat.org/RSMethods/index.html}is the primary documentation.The functions in this package emulate the facility for classesand methods described in \emph{Programming with Data} (JohnM. Chambers, Springer, 1998). See this book for further details andexamples.}\author{John Chambers}\seealso{ \code{\link{setClass}} }\examples{## representation for a new class with a directly define slot "smooth"## which should be a "numeric" object, and extending class "track"representation("track", smooth ="numeric")\testonly{setClass("class1", representation(a="numeric", b = "character"))setClass("class2", representation(a2 = "numeric", b = "numeric"))try(setClass("class3", representation("class1", "class2")))}}\keyword{programming}\keyword{classes}