decorators: Get Function Decorators or Original Function

Description Usage Arguments Examples

View source: R/helpers.R

Description

Get the decorators of a function or the original decoratee function from a decorated function object.

Usage

1
2
3

Arguments

f

A decorated function.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
source_decoratees(tinsel_example('attributes.R'))

# sourced from the 'attributes.R' example file
selector1

# get a list of decorators wrapping a function
decorators(selector1)

# get the original decoratee function of the
# decorated `selector1` function
original(selector1)

tinsel documentation built on May 2, 2019, 1:30 p.m.