Check a gdal_opts() object against its driver's registered metadata: unknown option names,
invalid enumerated (string-select) values, and invalid boolean values. Validation is advisory
and non-blocking - it warns (with classed conditions) and returns a logical, leaving the decision
to act at the call site.
Usage
validate_gdal_opts(x, driver = attr(x, "driver"), call = rlang::caller_env())Arguments
- x
A
gdal_open_opts(),gdal_creation_opts(), orgdal_config_opts()object.- driver
GDAL driver short name; defaults to the object's
driverattribute.- call
The execution environment of a currently running function, e.g.
caller_env(). The function will be mentioned in error messages as the source of the error. See thecallargument ofabort()for more information.
Value
Invisibly, TRUE if valid, FALSE if any problems were found, or NA if validation
could not be performed (no driver).
Examples
validate_gdal_opts(gdal_open_opts(LIST_ALL_TABLES = "NO", driver = "GPKG"))