Learn R Programming

R.oo (version 1.21.0)

getName.environment: Gets the name of an environment

Description

Gets the name of an environment, e.g. "R_GlobalEnv" or "0x01ddd060".

Usage

# S3 method for environment
getName(env, ...)

Arguments

...

Not used.

Value

Returns a character string.

See Also

environmentName().

Examples

Run this code
# NOT RUN {
  name <- getName(globalenv())
  print(name)
  stopifnot(identical(name, "R_GlobalEnv"))

  getName(new.env())
# }

Run the code above in your browser using DataLab