# NOT RUN {
#example based on a WFS endpoint responding at http://localhost:8080/geoserver/wfs
wfs <- WFSClient$new("http://localhost:8080/geoserver/wfs", serviceVersion = "1.1.1")
#get capabilities
caps <- wfs$getCapabilities()
#find feature type
ft <- wfs$findFeatureTypeByName("mylayer", exact = TRUE)
data <- ft$getFeatures()
data_with_filter <- ft$getFeatures(cql_filter = "somefilter")
#Advanced examples at https://github.com/eblondel/ows4R/wiki#wfs
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab