Learn R Programming

R.oo (version 1.26.0)

Class: The Class class describes an Object class

Description

Package: R.oo
Class Class

Object
~~|
~~+--Class

Directly known subclasses:

public static class Class
extends Object

The Class class describes an Object class. First of all, this class is most commonly used internally and neither the end user nor the programmer need to no about the class Class.

Usage

Class(name=NULL, constructor=NULL)

Arguments

name

Name of the class.

constructor

Constructor (function) of any Object class.

Fields and Methods

Methods:

$-
$<--
.DollarNames-
.subset2Internal-
[[-
[[<--
argsToStringGets the arguments of a function as a character string.
as.characterReturns a short string describing the class.
forNameGets a Class object by a name of a class.
getDetailsLists the fields and methods of a class.
getFieldsReturns the field names of a class.
getKnownSubclassesGets all subclasses that are currently loaded.
getMethodsReturns the method names of class and its super classes.
getNameGets the name of the class.
getPackageGets the package to which the class belongs.
getRdDeclarationGets the class declaration in Rd format.
getRdHierarchyGets the class hierarchy in Rd format.
getRdMethodsGets the methods of a class in Rd format.
getStaticInstanceGets the static instance of this class.
getSuperclassesGets the super classes of this class.
isAbstractChecks if a class is abstract or not.
isBeingCreatedChecks if a class is currently being initiated initiated.
isDeprecatedChecks if a class is deprecated or not.
isPrivateChecks if a class is defined private or not.
isProtectedChecks if a class is defined protected or not.
isPublicChecks if a class is defined public or not.
isStaticChecks if a class is static or not.
newInstanceCreates a new instance of this class.
printPrints detailed information about the class and its fields and methods.

Methods inherited from Object:
$, $<-, [[, [[<-, as.character, attach, attachLocally, clearCache, clearLookupCache, clone, detach, equals, extend, finalize, getEnvironment, getFieldModifier, getFieldModifiers, getFields, getInstantiationTime, getStaticInstance, hasField, hashCode, ll, load, names, objectSize, print, save

Author

Henrik Bengtsson

Details

The class Class describes the Object class or one of its subclasses. All classes and constructors created by setConstructorS3() will be of class Class. Its methods provide ways of accessing static fields and static methods. Its print() method will print detailed information about the class and its fields and methods.