Count the features of a layer
Value
The number of features, or NA when the driver would have to scan
the layer and force is FALSE. Any filter set on the layer applies.
Examples
ds <- gdal_open(system.file("extdata/test.gpkg", package = "GDAL7"))
feature_count(get_layer(ds, 1))
#> [1] 5
gdal_close(ds)