org.sigilaris.core.application.module.runtime

Members list

Type members

Classlikes

trait RoutedStateReducer[F[_], Path <: Tuple, Owns <: Tuple, Needs <: Tuple]

Path-bound routed state reducer for composed modules.

Path-bound routed state reducer for composed modules.

A RoutedStateReducer is a RoutedStateReducer0 bound to a specific Path. It REQUIRES all transactions to implement ModuleRoutedTx for routing.

This is created during module mounting when a ComposedBlueprint is bound to a path. The type bound T <: Tx & ModuleRoutedTx enforces the routing requirement at compile time.

Phase 5.5 update: Now explicitly models Owns and Needs like RoutedStateReducer0.

Type parameters

F

the effect type

Needs

the needed schema tuple (tuple of Entry types)

Owns

the owned schema tuple (tuple of Entry types)

Path

the mount path tuple

Attributes

Source
StateModule.scala
Supertypes
class Object
trait Matchable
class Any
final class StateModule[F[_], Path <: Tuple, Owns <: Tuple, Needs <: Tuple, Txs <: Tuple, +R](val tables: Tables[F, Owns], val reducer: R, val txs: TxRegistry[Txs], val tablesProvider: TablesProvider[F, Needs])(using val uniqueNames: UniqueNames[Owns], val prefixFreePath: PrefixFreePath[Path, Owns])

State module (path-bound).

State module (path-bound).

A StateModule is a deployed module at a specific path. It combines:

  • Path: the deployment location
  • Owns: the set of owned tables (now with computed prefixes)
  • Needs: the set of needed external tables
  • Reducer: the transaction processing logic (now path-aware)
  • Transactions: the set of supported transaction types
  • TablesProvider: provider for external table dependencies

StateModule is generic in the reducer type R, which can be either:

  • StateReducer[F, Path, Owns, Needs] for single modules (accepts any Tx)
  • RoutedStateReducer[F, Path, Owns, Needs] for composed modules (requires ModuleRoutedTx)

This preserves compile-time type safety throughout the entire stack.

Phase 5.5 update: Schema split into Owns/Needs, Deps replaced by TablesProvider.

Type parameters

F

the effect type

Needs

the needed schema tuple (tuple of Entry types)

Owns

the owned schema tuple (tuple of Entry types)

Path

the mount path tuple

R

the reducer type (covariant)

Txs

the transaction types tuple

Value parameters

prefixFreePath

evidence that all owned table prefixes are prefix-free

reducer

the path-bound reducer

tables

the owned table instances (with prefixes bound to Path)

tablesProvider

the provider for external table dependencies

txs

the transaction registry

uniqueNames

evidence that table names are unique within Owns

Attributes

Companion
object
Source
StateModule.scala
Supertypes
class Object
trait Matchable
class Any
object StateModule

Companion for StateModule, providing mounting, composition, and factory operations.

Companion for StateModule, providing mounting, composition, and factory operations.

Attributes

Companion
class
Source
StateModule.scala
Supertypes
class Object
trait Matchable
class Any
Self type
trait StateReducer[F[_], Path <: Tuple, Owns <: Tuple, Needs <: Tuple]

Path-bound state reducer for single modules.

Path-bound state reducer for single modules.

A StateReducer is a StateReducer0 bound to a specific Path. It knows exactly where its tables are located in the trie.

This is created during module mounting when a ModuleBlueprint is bound to a path. It accepts any transaction type T <: Tx.

Phase 5.5 update: Now explicitly models Owns and Needs like StateReducer0.

Type parameters

F

the effect type

Needs

the needed schema tuple (tuple of Entry types)

Owns

the owned schema tuple (tuple of Entry types)

Path

the mount path tuple

Attributes

Source
StateModule.scala
Supertypes
class Object
trait Matchable
class Any