|Web Feature Service (WFS) / Using Web Feature Service Capabilities Through HTTP Request|
Consumers of WFS would apply filters to selectively retrieve features from a WFS server based on certain conditions being met in the Get Feature Request. These conditions are expressed in the form of filters, which are the XML equivalent of boolean expressions. A boolean expression either returns a "true" or a "false" for every feature in a Content. For example, consider the expression "Age > 30". Using this filter, only features with the age attribute greater than 30 are returned.
Filters can be a simple expression as in the previous example or they can be complex, formed by combining simple expressions using logical OR, AND, and NOT operators. For example:
Age > 30 AND Name like 'John'
Filters can also be spatial. A spatial filter can be used to search features based on their geographic attribute. For example, find all features that are within 10 miles of a given point.
Three types of filters are supported by the WFS: attribute, spatial, and logical.