ErrorControllerList: ErrorControllerList

Description Usage Methods

Description

Reactive R6Class that returns HTML according to a test function. Modules like checked_text_input or observed_vector_input provide a argument accepting an ErrorController or ErrorControllerList that expands the module's default tests.

Usage

1
2
3
4
5
6
7
8
9
error_controller <- shiny::isolate({
  ErrorControllerList$new()$add_error_controller(
    ErrorController$new(
      fun = function(x) purrr::is_null(x),
      ui_true = "x is NULL",
      ui_false = "x is not NULL",
      error = TRUE
    )
  )})

Methods

new()

Initialize the error controller list.

add_error_controller(error_controller)

Add an ErrorController to the error controller list.

get_ui()

Get the UI of all ErrorController as a list ordered by the priority of the respective ErrorController.

has_error()

Returns TRUE if any of the ErrorController has an error.

set_value(value)

Sets the value of all ErrorController.


DavidBarke/QWUtils documentation built on Jan. 13, 2020, 11:52 a.m.