This is a generic definition that can be extended according to class.
.cacheMessage(
object,
functionName,
fromMemoise = getOption("reproducible.useMemoise", TRUE),
verbose = getOption("reproducible.verbose", 1)
)
# S4 method for ANY
.cacheMessage(
object,
functionName,
fromMemoise = getOption("reproducible.useMemoise", TRUE),
verbose = getOption("reproducible.verbose", 1)
)
Any R object.
A character string indicating the function name
Logical. If TRUE
, the message will be about
recovery from memoised copy
Numeric, -1 silent (where possible), 0 being very quiet,
1 showing more messaging, 2 being more messaging, etc.
Default is 1. Above 3 will output much more information about the internals of
Caching, which may help diagnose Caching challenges. Can set globally with an
option, e.g., options('reproducible.verbose' = 0) to reduce to minimal
Nothing; called for its messaging side effect.
a <- 1
.cacheMessage(a, "mean")
#> loaded cached result from previous mean call (and added a memoised copy)