check_curl: Check if curl is avaiable for given API URL(s)

Description Usage Arguments Value Author(s) Examples

Description

Check if curl is avaiable for given API URL(s)

Usage

1
2
check_curl(url, app_name = gsub("^[^/]+//(.*)$", "\\1", url),
  use_curl = TRUE, messaging = FALSE)

Arguments

url

character vector of API URLs

app_name

character vector of API app name. If missing, url will be used as the name(s)

use_curl

logical, whether to use curl. The function will check the url(s) only when use_curl = TRUE. Default TRUE.

messaging

logical, whether print messages while processing. Default FALSE.

Value

a logical vector corresponding to url.

Author(s)

Yiying Wang, wangy@aetna.com

Examples

1
2
3
4
5
6
7
## Not run: 
check_curl(c("http://www.baidu.com",'https://www.google.com'))  # returns

# www.baidu.com www.google.com
#         FALSE           TRUE

## End(Not run)

madlogos/aseskit documentation built on June 26, 2019, 12:17 a.m.