Description Usage Arguments Value Fields Intended use of this class Author(s) References See Also Examples
File class (S3).
1 | FilePath.S3(.x, path = NA_character_)
|
.x |
|
Instance of class FilePath.S3
.
path
character
. File path.
This S3 class, or to be more precise its constructor function, exists mainly
for rapid prototyping purposes.
This is mainly reflected in the fact, that when specifying .x
, this
constructor function will simply update the class
attribute of
whatever object has been provided.
However, it also allows for a more formal OOP-style of rapid
prototyping by offering explicit class fields (all arguments except
.x
). Nevertheless, it is probably advisable to switch to an
explicit formal approach such as S4 and/or Reference Classes
once the package or application has reached a certain state of maturity.
Janko Thyson janko.thyson@rappster.de
https://github.com/Rappster/filesystr
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | ## Not run:
## Informal use (intended mainly for rapid prototyping) //
## Takes *any* object and simply changes the class attributes
FilePath.S3(tempfile())
FilePath.S3(rep(tempfile(), 3))
FilePath.S3(as.list(rep(tempfile(), 3)))
FilePath.S3(TRUE)
## Formal use (explicitly using 'fields') //
FilePath.S3()
FilePath.S3(path = tempfile())
FilePath.S3(path = rep(tempfile(), 3))
FilePath.S3(path = as.list(rep(tempfile(), 3)))
## Recommended: inlcude namespace //
filesystr::FilePath.S3(tempfile())
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.