Learn R Programming

mirai (version 2.2.0)

unresolved: Query if a mirai is Unresolved

Description

Query whether a 'mirai', 'mirai' value or list of 'mirai' remains unresolved. Unlike call_mirai(), this function does not wait for completion.

Usage

unresolved(x)

Value

Logical TRUE if x is an unresolved 'mirai' or 'mirai' value or the list contains at least one unresolved 'mirai', or FALSE otherwise.

Arguments

x

a 'mirai' object or list of 'mirai' objects, or a 'mirai' value stored at $data.

Details

Suitable for use in control flow statements such as while or if.

Note: querying resolution may cause a previously unresolved 'mirai' to resolve.

Examples

Run this code
if (FALSE) { # interactive()
m <- mirai(Sys.sleep(0.1))
unresolved(m)
Sys.sleep(0.3)
unresolved(m)
}

Run the code above in your browser using DataLab