Servers that support the Web Feature Service (WFS) specification from the Open Geospatial Consortium (OGC) provide access to vector feature data over the internet. Although the protocol has been around for some time (it's been implemented in Cartographica and CartoMobile for a number of years now), it is not as popular as other online map format services, such as Web Map Service (WMS), Web Map Tile Service (WMTS). However, it has a unique feature that it actually provides geometric data instead of just visual representations. As such, the geometric fidelity and associated information can be substantial. In addition, there is a writable version of the service (WFS‑T, Web Feature Service-Transactional) which can be used to write data back to the server. Although Cartographica does not support WFS‑T as of this writing, CartoMobile does support it as a mechanism for implementing remote data collection.
Cartographica considers WFS to be a data source, but locally caches information retrieved from the server so that it can be used offline.
Acquire data from a WFS Server
Acquire feature data over the internet from a OGC-compliant WFS Server
The Add Web Feature Layer sheet appears
Type or paste the URL for the WFS server into Server URL
Type or paste the name of the chosen layer into Layer
Cartographica will add a layer to the Layer Stack with the name of the layer and will retrieve the information from the WFS server. If the server is unavailable or requires a password, you will be prompted for any supplemental information.
Editing Existing WFS Layers
It is possible to change the parameters for an existing WFS layer. To do so:
The Add Web Feature Layer sheet appears with the current data pre-filled
Change parameters as desired
the filter is re-run and any new items are added to the local copy of the layer. It's important to remember that existing features are not deleted, so you will have to manually remove them if you want them taken out of the layer
There are times when a WFS layer contains a combination of relevant and irrelevant data. In those cases, the Filter box in Add Web Feature Layer can be used to limit what is downloaded from the server. The form of the filter is an expression that is evaluated by the WFS server and can be pretty esoteric. It is suggested that if you want to filter the information, you coordinate with your WFS server administrator or consult the documentation for the provided layers in order to determine the format and function of the filters. Some examples follow.
Example 3.1. Filter by property
<ogc:PropertyIsGreaterThan> <ogc:PropertyName>DATE_</ogc:PropertyName> <ogc:Literal>'2012-09-15'</ogc:Literal> </ogc:PropertyIsGreaterThan>
This filter looks for features that have property that is named
which is greater than
The formatting needs to be precise and Cartographica will validate it with the server,
so that you can make changes and re-submit if necessary.
Example 3.2. Filter by property
<ogc:And> <ogc:PropertyIsGreaterThan> <ogc:PropertyName>DATE_</ogc:PropertyName> <ogc:Literal>'2012-09-15'</ogc:Literal> </ogc:PropertyIsGreaterThan> <ogc:PropertyIsEqualTo> <ogc:PropertyName>SOURCE</ogc:PropertyName> <ogc:Literal>BIC</ogc:Literal> </ogc:PropertyIsEqualTo> </ogc:And>
This more complex filter builds upon the previous filter and also requires
SOURCE property be equal to
Note the use of the outer
And command to dictate that feature match both conditions.
You could also use an
Or here to dictate that matching either condition be matched.
The specific operators available may vary by server, but they generally take the same form and are always represented by XML.