Debian Codegraph @

man/reactiveValuesToList.Rd

raw
1 % Generated by roxygen2: do not edit by hand
2 % Please edit documentation in R/reactives.R
3 \name{reactiveValuesToList}
4 \alias{reactiveValuesToList}
5 \title{Convert a reactivevalues object to a list}
6 \usage{
7 reactiveValuesToList(x, all.names = FALSE)
8 }
9 \arguments{
10 \item{x}{A \code{reactivevalues} object.}
11
12 \item{all.names}{If \code{TRUE}, include objects with a leading dot. If \code{FALSE}
13 (the default) don't include those objects.}
14 }
15 \description{
16 This function does something similar to what you might want or expect
17 \code{\link[base:list]{base::as.list()}} to do. The difference is that the calling context will take
18 dependencies on every object in the \code{reactivevalue}s object. To avoid taking
19 dependencies on all the objects, you can wrap the call with \code{\link[=isolate]{isolate()}}.
20 }
21 \examples{
22 values <- reactiveValues(a = 1)
23 \dontrun{
24 reactiveValuesToList(values)
25 }
26
27 # To get the objects without taking dependencies on them, use isolate().
28 # isolate() can also be used when calling from outside a reactive context (e.g.
29 # at the console)
30 isolate(reactiveValuesToList(values))
31 }