| Line 28... |
Line 28... |
| 28 |
|
28 |
|
| 29 |
existsMethod(f, signature = character(), where)
|
29 |
existsMethod(f, signature = character(), where)
|
| 30 |
|
30 |
|
| 31 |
hasMethod(f, signature=character(), where)
|
31 |
hasMethod(f, signature=character(), where)
|
| 32 |
|
32 |
|
| 33 |
selectMethod(f, signature, optional=FALSE, useInherited,
|
33 |
selectMethod(f, signature, optional = FALSE, useInherited = TRUE,
|
| 34 |
mlist=getMethods(f), fdef = getGeneric(f))
|
34 |
mlist = (if (is.null(fdef)) NULL else getMethods(fdef)),
|
| - |
|
35 |
fdef = getGeneric(f, !optional))
|
| 35 |
|
36 |
|
| 36 |
MethodsListSelect(f, env, mlist, fEnv, finalDefault, evalArgs,
|
37 |
MethodsListSelect(f, env, mlist, fEnv, finalDefault, evalArgs,
|
| 37 |
useInherited, fdef, resetAllowed)
|
38 |
useInherited, fdef, resetAllowed)
|
| 38 |
|
39 |
|
| 39 |
}
|
40 |
}
|
| Line 183... |
Line 184... |
| 183 |
While the programming interface for the \pkg{methods} package follows
|
184 |
While the programming interface for the \pkg{methods} package follows
|
| 184 |
the reference, the R software is an original implementation, so
|
185 |
the reference, the R software is an original implementation, so
|
| 185 |
details in the reference that reflect the S4 implementation may appear
|
186 |
details in the reference that reflect the S4 implementation may appear
|
| 186 |
differently in R. Also, there are extensions to the programming
|
187 |
differently in R. Also, there are extensions to the programming
|
| 187 |
interface developed more recently than the reference. For a
|
188 |
interface developed more recently than the reference. For a
|
| 188 |
discussion of details and ongoing development, see the web page
|
189 |
discussion of details and ongoing development, see the web page
|
| 189 |
\url{http://developer.r-project.org/methodsPackage.html} and the
|
190 |
\url{http://developer.r-project.org/methodsPackage.html} and the
|
| 190 |
pointers from that page.
|
191 |
pointers from that page.
|
| 191 |
}
|
192 |
}
|
| 192 |
\examples{
|
193 |
\examples{
|
| 193 |
setGeneric("testFun", function(x)standardGeneric("testFun"))
|
194 |
setGeneric("testFun", function(x)standardGeneric("testFun"))
|