Show/Hide Toolbars

Every view has a view filter. Together with the view filters of all views on a specific views path the filter defines the members features of the view. View filters are constructed by combining atomic view filter terms with combination  nodes (logical operators) in a tree-like structure. See figure 1 for an example. There is no limit to the number of filter terms or combination nodes and there is also no limitation on the depth of the tree structure.

Figure 1: Example of a view filter tree structure. A, B, C, D are the atomic view filter terms, NOT OR and AND the combination nodes

Each view filter consists of a filter tree with exactly one root combination node. A combination node can have any number of subordinate combination nodes and/or filter terms. A combination node represents a logical operator. It can be configured to be an AND or an OR operator. Additionally it can be negated to form NOT AND and NOT OR operators.

In Figure 1 the root combination node is the NOT OR node, it has one subordinate combination node and two subordinate filter terms (C and D).

View filter terms can only be subordinate terms of a combination nodes. View filter terms are always leaf nodes within the tree structure, i.e. they cannot have any subordinate combination nodes or subordinate filter terms. Each term is of a specific predefined view filter term type. Each view filter term type may expose user configurable properties.

The actual view filter is built by evaluating the tree structure from the leaves to the root, therefore you can define the precedence of the term combination by structuring the tree accordingly. Figure 2 shows some examples of view filter tree structures and their logical equivalent.

Figure 2: Examples for view filters with their mathematical equivalents. Red framed combination nodes are deactivated nodes.

Figure 2:1 and 2:2 result in the same filter. Since there is only one filter term there is no difference if the combination node is configured as an AND or an OR combination node.

Figure 2:2 and 2:3 show the usage of the negation operator for a view filter with a single term. These two filters also result in the same filter. Since there is only one filter term there is no difference if the combination node is configured as an NOT AND or an NOT OR combination node.

Figure 2:5 and Figure 2:7 shows multiple terms beneath a single combination term. The combination node's logical operator will be applied to all of its subordinate terms. When the logical operator of the node is negated (figure 2:6, figure 2:8) the negation is applied after the combination.

Figure 2:9 and figure 2:10 show examples of more complex view filters. As you can see the actual filter is created bottom up i.e. from the leaf nodes to the parent. The tree structure defines the evaluation precedence.

Combination terms and nodes can be deactivated. Deactivated parts of the tree structure will not be included in the actual filter expression for the view. Figure 2:11 and figure 2:12 show the effect of deactivating parts of a view tree.

View filters always filter for features i.e. they always return a set of features. Since one feature can have many observations a filter term type that queries on characteristics of observations needs to define an additional criteria - the count criteria. The system supports following count criteria: All, Any and None. E.g. if a view filter contains a term that filters for features that have observations within a specific time span you can define if the feature is included in the resulting feature set if all, any or none observations are in that time span.

If the view filter term type queries for specific property values of a property structure that is stored for the feature or the feature's observations that property might also be contained in a property collection and therefore there might be more than one occurrence of the property. Accordingly view filter term types that query for properties also have a count criteria setting. View filter term types that filter on data of features that are related to the feature through one or more more a one to many relationship will always include the count criteria setting for each one to many relationship.

The Application Server will not allow to store views with an empty view filter. If you store an view definition with an empty view filter or with a view filter that has only one root combination node the Application Server will automatically replace the view filter with either a contradiction filter (if the view is a root view) or with a tautology filter (if the view is subordinate of another view).

© 2021 AFRY Austria GmbH, www.redbex.com