RC++Reference-class | R Documentation |
The class RC++Reference
is the class that holds the address of a C++ object.
With the programmatically constructed code (or manually)
we can then invoke its C++ methods and access its public fields from within R and generally
manipulate the C++ object.
The class RC++ReferenceUseName
class is a simple extension of
RC++Reference
which exploits the fact that the R
functions corresponding to the C++ methods for an instance are of the
form class_<method name>
, e.g. MyClass_plot for a reference
class named MyClassPtr
.
Objects can be created by calls of the form new("RC++Reference", ...)
.
They are usuall returned from calls to R functions that call C++ code
to create the object.
ref
:Object of class "externalptr"
this is the
R object that holds the address of the C++ object.
classes
:Object of class "character"
the name
of R classes that correspond to the C++ class hierarchy.
signature(obj = "RC++Reference", finalizer = "logical")
:
signature(obj = "RC++Reference", finalizer = "NativeSymbolInfo")
:
signature(obj = "RC++Reference", finalizer = "NativeSymbol")
:
signature(obj = "RC++Reference", finalizer = "function")
:
signature(x = "RC++Reference")
: ...
signature(obj = "RC++Reference")
: ...
Duncan Temple Lang
“Writing R Extensions Manual”, R Development Core Team
The RAutoGenRunTime package for programmatically reading C/C++ code and generating bindings for the data structures, methods and routines.
showClass("RC++Reference")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.