cache-cache: Helper functions for package caching

Description Usage Arguments Value Examples

Description

Both setCache and getCache allow maintainers / developers to specify cache locations for the package they wish to implement a caching mechanism. This avoids the maintainer the use of BiocFileCache directly by providing a simple option called 'pkgName' which indicates the name of the package being developed.

Usage

1
2
3
4
setCache(directory = rappdirs::user_cache_dir(getOption("pkgName")),
  verbose = TRUE, ask = interactive())

getCache()

Arguments

directory

location on disk intended for caching files

verbose

logical (default FALSE) whether to report procedural steps

ask

logical (default 'interactive()“) whether to ask the user to confirm the cache location

Value

setCache: Modifies 'pkgName' and <pkg>_cache options and creates directory if not available

A BiocFileCache instance for the package specified in the 'pkgName' option

Examples

1
2
## options(pkgName = "cacheur")
setCache()

waldronlab/cacheur documentation built on June 16, 2019, 5:06 p.m.