The hardware and bandwidth for this mirror is donated by METANET, the Webhosting and Full Service-Cloud Provider.
If you wish to report a bug, or if you are interested in having us mirror your free-software or open-source project, please feel free to contact us at mirror[@]metanet.ch.
A decorator is a function that receives a function, extends its behaviour, and returned the altered function. Any caller that uses the decorated function uses the same interface as it were the original, undecorated function. Decorators serve two primary uses: (1) Enhancing the response of a function as it sends data to a second component; (2) Supporting multiple optional behaviours. An example of the first use is a timer decorator that runs a function, outputs its execution time on the console, and returns the original function's result. An example of the second use is input type validation decorator that during running time tests whether the caller has passed input arguments of a particular class. Decorators can reduce execution time, say by memoization, or reduce bugs by adding defensive programming routines.
Version: | 0.3.0 |
Depends: | R (≥ 3.5) |
Imports: | purrr, methods |
Suggests: | testthat |
Published: | 2022-09-30 |
DOI: | 10.32614/CRAN.package.decorators |
Author: | Harel Lustiger [aut, cre], Tidylab [cph, fnd] |
Maintainer: | Harel Lustiger <tidylab at gmail.com> |
BugReports: | https://github.com/tidylab/decorators/issues |
License: | MIT + file LICENSE |
URL: | https://tidylab.github.io/decorators/, https://github.com/tidylab/decorators |
NeedsCompilation: | no |
Language: | en-GB |
Citation: | decorators citation info |
Materials: | README NEWS |
CRAN checks: | decorators results |
Reference manual: | decorators.pdf |
Package source: | decorators_0.3.0.tar.gz |
Windows binaries: | r-devel: decorators_0.3.0.zip, r-release: decorators_0.3.0.zip, r-oldrel: decorators_0.3.0.zip |
macOS binaries: | r-release (arm64): decorators_0.3.0.tgz, r-oldrel (arm64): decorators_0.3.0.tgz, r-release (x86_64): decorators_0.3.0.tgz, r-oldrel (x86_64): decorators_0.3.0.tgz |
Old sources: | decorators archive |
Please use the canonical form https://CRAN.R-project.org/package=decorators to link to this page.
These binaries (installable software) and packages are in development.
They may not be fully stable and should be used with caution. We make no claims about them.