QueryModels

interface QueryModels

The query models one caller (Queries) or trusted code (TrustedQueries) reads. A row of a type the reader names no class of, a state read by its type or an event no class of the model has, is an ObjectNode, in process and over HTTP alike.

Inheritors

Functions

Link copied to clipboard
abstract fun <R : Any> datasets(name: DatasetName, rowType: Class<R>): RowQueries<R>

The rows of the dataset name (context.dataset), decoded as rowType: a class of the dataset's columns, or ObjectNode. Experimental, as the dataset surface is.

Link copied to clipboard

The rows of the dataset name decoded as R; see QueryModels.datasets.

Link copied to clipboard
abstract fun events(type: AggregateType): EventQueries

The event streams of type: one row per commit, each event's body decoded as the model's class of it, an ObjectNode for an event it has no class of.

Link copied to clipboard
abstract fun <S : Any> snapshots(stateType: Class<S>): SnapshotQueries<S>

The snapshots of the aggregate whose state is of stateType (its root's class when the root is its own state), their rows decoded as Snapshots of it. The node finds the aggregate type from its models.

abstract fun snapshots(type: AggregateType): SnapshotQueries<ObjectNode>

The snapshots of type, their states as stored (ObjectNode): read their fields by the constants of the aggregate's contract.