R6 v2.2.2

0

Monthly downloads

0th

Percentile

Classes with Reference Semantics

The R6 package allows the creation of classes with reference semantics, similar to R's built-in reference classes. Compared to reference classes, R6 classes are simpler and lighter-weight, and they are not built on S4 classes so they do not require the methods package. These classes allow public and private members, and they support inheritance, even when the classes are defined in different packages.

Readme

R6 classes

Build Status

AppVeyor Build Status

This package contains an implemention of classes with reference semantics, and it is a simpler, faster, lighter-weight alternative to R's built-in reference classes.

Additionally, these classes are not built on S4 classes, so they do not require the methods package. They allow public and private members, and they support inheritance. Unlike reference classes, R6 classes can be cleanly inherited across different packages, when used in portable mode (enabled by default).

Why the name R6? When R's reference classes were introduced, some users, following the names of R's existing class systems S3 and S4, called the new class system R5 in jest. Although reference classes are not actually called R5, the name of this package and its classes takes inspiration from that name.

The name R5 was also a code-name used for a different object system started by Simon Urbanek, meant to solve some issues with S4 relating to syntax and performance. However, the R5 branch was shelved after a little development, and it was never released.

Installation

To install R6 from CRAN:

install.packages('R6')

To install the development version (requires the devtools package):

devtools::install_github('wch/R6', build_vignettes = FALSE)

Documentation

Functions in R6

Name Description
R6Class Create an R6 reference object generator
as.list.R6 Create a list from an R6 object
is.R6 Is an object an R6 Class Generator or Object?
No Results!

Vignettes of R6

Name
Debugging.Rmd
Introduction.Rmd
Performance.Rmd
Portable.Rmd
mystyle.css
No Results!

Last month downloads

Details

License MIT + file LICENSE
URL https://github.com/wch/R6/
LazyData true
VignetteBuilder knitr
RoxygenNote 6.0.1
NeedsCompilation no
Packaged 2017-06-12 18:48:43 UTC; winston
Repository CRAN
Date/Publication 2017-06-17 08:22:59 UTC

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/R6)](http://www.rdocumentation.org/packages/R6)