sc98-Directory-class: Class "Directory"

Description Usage Arguments Value Objects from the Class Slots Methods Note Author(s) See Also Examples

Description

The Directory class represents a file system directory.

Usage

1
2
3
4
5
6
Directory(path)
is.Directory(x)
## S4 method for signature 'character,Directory'
coerce(from, to, strict=TRUE)
## S4 method for signature 'Directory,character'
coerce(from, to, strict=TRUE)

Arguments

path

character string specifying a directory

x

object of class Directory

from

object of class Directory or character string specifying pathname of directory

to

object of class Directory or character string specifying pathname of directory

strict

logical scalar. If TRUE, the returned object must be strictly from the target class; otherwise, any simple extension of the target class will be returned, without further change.

Value

The Directory generator returns an object of class Directory.

The is.Directory method returns TRUE if its argument is an object of class Directory.

Objects from the Class

Although objects of the class can be created by a direct call to new, the preferred method is to use the Directory generator function.

Slots

path:

character string specifying a directory

Methods

coerce

signature(from = "Directory", to = "character"):
Coerce an object of class Directory to its character string pathname equivalent.

coerce

signature(from = "character", to = "Directory"):
Coerce a character string specifying directory pathname to an equivalent object of class Directory.

Note

The coercion methods should not be called explicitly; instead, use an explicit call to the as method.

Author(s)

P. Roebuck proebuck@mdanderson.org

See Also

as

Examples

1
2
  pkgdir <- Directory(system.file(package="SuperCurve"))
  pkgdir.path <- as(pkgdir, "character")

SuperCurve documentation built on May 2, 2019, 6:14 p.m.