Restrictions
The Search API supports various types of Restrictions, all of which belong to the interface class 'Search restriction' (ISearchJunction):
Each restriction type determines a Boolean return value (true/false) according to a specific characteristic in order to determine whether a certain 'candidate' (an entity instance or tuple line to be evaluated in the context of the search) has 'passed' the rule formulated as a restriction or not.
The data model of different classes refers to the interface class 'Search restriction' to enable the configuration of Restrictions:
All Search types in the context of the Search API allow the definition of Restrictions:
Each 'search' provides for the definition of one restriction in the 'Where' condition (where) property, which can, however, contain quite complex logic due to the cascading use of the Search junction.
Joins can be used in all Search types and via the Chained projection to integrate the data of entities into a 'search', the assignment of which is typically governed by a restriction defined by the 'On' condition (on) property.
The Subsearch projection also defines the access to data of a subset of instances of a specific entity type based on the restriction defined for the 'Where' condition (where) property.
Other classes that imply the execution of a search or require other 'filtering' of search results also use Restrictions, e.g.:
For Custom overviews, a 'Search restriction' in the 'Restriction' (restriction) property can control which subset of the instances of the entity type to be displayed appear in the overview.
Custom overviews also always offer a data grid for which conditional row formatting can be defined on the basis of Restrictions (see Row formatting in datagrids).
If a 'Search' object is passed to the Öffne View (Aktion) event action when an overview is opened, then a 'Where' condition defined in it applies as a restriction for the opened overview.
Last but not least, the Search junction and Sub search restriction types provide for the configuration of Restrictions in their definition.