Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

clone.Object

Clones an Object


Description

Creates an identical copy of the object and returns a reference to the new object.

Usage

## S3 method for class 'Object'
clone(this, ...)

Arguments

...

Not used.

Details

Please note that no constructors are called during the creation of the clone and neither is any static class code called.

Value

A reference to the new object.

Author(s)

Henrik Bengtsson

See Also

For more information see Object.

Examples

o1 <- Object()
  o2 <- clone(o1)

  print(equals(o1, o2))

R.oo

R Object-Oriented Programming with or without References

v1.24.0
LGPL (>= 2.1)
Authors
Henrik Bengtsson [aut, cre, cph]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.