is_pre_stagerunner: Whether or not an object can be transformed into a...

Description Usage Arguments Value Examples

Description

Whether or not an object can be transformed into a stageRunner.

Usage

1

Arguments

x

ANY. An R object for which it will be determined whether or not it admits a conversion to a stageRunner.

Value

TRUE or FALSE according to whether the object can be transformed to a stageRunner. In general, only a function or list of functions can be turned into a stageRunner.

Examples

1
2
3
4
5
6
7
8
9
stopifnot(is_pre_stagerunner(function(e) { e$x <- 1 }))
stopifnot(is_pre_stagerunner(list(function(e) { e$x <- 1 }, function(e) { e$y <- 2 })))
stopifnot(is_pre_stagerunner(
  list(a = function(e) { e$x <- 1 },
    list(b = function(e) { e$y <- 2 }, c = function(e) { e$z <- 3 }))))

stopifnot(!is_pre_stagerunner(NULL))
stopifnot(!is_pre_stagerunner(5))
stopifnot(!is_pre_stagerunner(iris))

syberia/stagerunner documentation built on May 30, 2019, 10:41 p.m.