Skip to content

Release 1.17.0

Choose a tag to compare

@reid-spencer reid-spencer released this 28 Mar 22:53
· 32 commits to main since this release

Release 1.17.0

New Feature: Finder.findInParents

Added Finder.findInParents[T](parents: Parents): Seq[(T, Parents)] to the Finder companion object. This method searches the contents of each parent in a hierarchy chain for definitions matching a given type parameter.

Use case: Finding definitions that are "in scope" at a given point in the AST hierarchy. For example, finding all Command type definitions visible from a Handler by walking up its parent chain (Entity → Context → Domain).

Returns: Each matching definition paired with the parent chain of the container it was found in, suitable for constructing a PathIdentifier.

// Find all Command types visible from a handler's parent chain
val handlerParents = Parents(entity, context, domain, root)
val commands = Finder.findInParents[Type](handlerParents)
// Returns: Seq[(Type, Parents)] with types from entity, context, and domain

This is a backward-compatible addition — no existing APIs were changed.