Description Usage Arguments Details Value Examples
logFileName
returns path and name of a file for logging events, or
sets the global option rete.logfile.
1 | logFileName(fPath, fName, setOption = FALSE)
|
fPath |
A path to a log-file directory. If missing the path is set to getwd(). |
fName |
Name of file to which log messages will be appended. If missing, a new filename is generated. |
setOption |
Whether to set the global option rete.logfile. Defaults to FALSE. |
If fPath is missing, the function checks whether getwd() contains a
directory called "logs". If yes, log files will be written to that
directory, if no, getwd() will be used as the path. This default behaviour
also defines the initial log file path and name on loading the package. A
single "/" (or "\"), path separator is removed from fPath if present, since
the file.path() function will add a path separator which would result in
doubling it otherwise. The default file name is structured as
"rete_YYY-MM-DD.d.log" where YYY-MM-DD is the value of Sys.Date() and d is
an integer that is one larger than the highest integer in a filename
structured this way in the fPath directory. Thus the file name is unique.
If the requested filename does not end with the extension ".log", that
extension is added. If you must have a logfile named with a different
extension, you can set it directly via options("rete.logfile") <-
<my.special.name>. If setOption is TRUE, the function sets the global
option rete.logfile to which logMessage
appends log events.
Path and name of a file that can be used to log events.
## @family TBD
## @seealso logMessage
...
1 2 3 4 5 | logFileName()
## Not run:
logFileName(fPath = "./logs", setOption = TRUE)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.