Forester 4.2 › New query language › Relational queries › Query modes and polarities [00WZ]
Given an address x and a relation symbol r, there are several useful queries that we might wish to make:
- We might wish to find all incoming edges to
xinr, or we may wish to find all outgoing edges fromxinr. We shall refer to the differenec between incoming and outgoing edges is referred to as a polarity. - Rather than searching for edges, we may wish to search for paths — which corresponds to passing from a relation to its preorder reflection. We will refer to this distinction as a mode.
Forester supports both polarities and modes for relational queries via the following built-in constants:
\query/incomingand\query/outgoingdenote the two polarities.\query/edgesand\query/pathsrepresent the two modes.