AccessFilterSpec
The access filter contract: every snapshot query backend answers an access policy's filter (AccessFilters) as the kernel evaluates the policy (AccessPredicate.allows), so a policy grants the same aggregates whether a query, a point read or a command asks. A backend's test extends it, stores the records each test gives in store, and supplies its binding of an aggregate type in binding; on the in-memory backend it is the matrix that holds the kernel's evaluator to the point reads', on the others the access attributes' push-down. A snapshot store keeps no record not stamped (keepsUnstamped).
Each record holds an aggregate's access attributes as its snapshot does: the built-in owner and space as owner and space (ownerId and spaceId; an event stream's access.owner and access.space), each declared attribute under fieldOf it, access.<name> by default, its value as stored (accessTree: a string, an enum by its name, an integer as a long, a boolean, a multiple attribute a sorted array of distinct values, an explicit null for one without a value), and no key for an attribute declared since it was stamped: a record written before the attribute was declared. A record not yet stamped has a null access.
The rule of a missing key (#7370): a comparison of a declared attribute a record holds no key of holds neither way, IS_NULL included, as a comparison with a claim the caller does not hold (AccessPredicate.Unknown); the expected rows read each record so (grants). A state holds every declared attribute, so the kernel's evaluation of a state (AccessPredicate.allows) never meets one. The built-in owner and space have no such case: every stamp holds them, and a missing one is null. On a store that keeps such records (keepsUnstamped) every filter is guarded by IS_NOT_NULL of access, as the query assembly guards an events query, so a record not stamped is never read, not even by a check of absence; on a snapshot store, whose records are always stamped, there is no guard, as the assembly sends none for snapshots.
The matrix covers each operator of one value and of several, negated or not, on present values, on values a record lacks and on a record not stamped, with claims the caller holds and those it does not: a negation over a missing value never grants (a document store's $nor matches a missing field, which the guard of each negation excludes).
Types
An aggregate's access attributes: its id, its owner and space, and the values of its declared attributes by name (a multiple one's a collection, an enum's its constant), null for one without a value, no key for one declared since the record was stamped; stamped false for a record holding no attribute at all.
The attributes of the matrix's documents.
Functions
The matrix over records none of which holds a value of an attribute but its department (#7475): each other one null, the empty set, or missing. A store that maps an attribute as it meets a value of it, as Elasticsearch maps access, has met none; each comparison is still answered as the kernel evaluates it, not refused.
A caller's EXISTS and NOT_EXISTS of a declared attribute read whether the record holds its key, null or not (#7370): level has a value in d1 and d2, is null in d3, and is missing from d4 and d6, written before it was declared; department is null in d3 only. On every backend alike, as the policy's IS_NULL relies on.