Part of #5110. Target repo: JasperFx/jasperfx (tracked here per program convention; the actual PR lands there and rides a routine version bump into Marten and Polecat).
Add default interface methods to JasperFx.Events.IEventRegistry (src/JasperFx.Events/IEventRegistry.cs):
void AddEventType<T>() => AddEventType(typeof(T));
IEventType EventMappingFor<T>() => EventMappingFor(typeof(T));
Why: today only the non-generic forms are shared. Marten's EventMappingFor<T>() is internal (reachable only via InternalsVisibleTo — the compliance library has a zero-IVT rule) and returns EventMapping; Polecat's public override takes Type and returns PolecatEventType. Both concrete types implement IEventType, so the DIM unifies the assertion surface (.EventTypeName) for all test code in both repos, not just the compliance suites.
Non-breaking: DIMs only; existing store-specific members are unaffected (Marten's internal generic can later be retired independently).
Sequencing: not a hard blocker for P3.1 (the seam can call the Type-based forms), but landing it before P3.3 extraction lets the shared sources use the generic forms directly.
🤖 Generated with Claude Code
Part of #5110. Target repo: JasperFx/jasperfx (tracked here per program convention; the actual PR lands there and rides a routine version bump into Marten and Polecat).
Add default interface methods to
JasperFx.Events.IEventRegistry(src/JasperFx.Events/IEventRegistry.cs):Why: today only the non-generic forms are shared. Marten's
EventMappingFor<T>()is internal (reachable only via InternalsVisibleTo — the compliance library has a zero-IVT rule) and returnsEventMapping; Polecat's public override takesTypeand returnsPolecatEventType. Both concrete types implementIEventType, so the DIM unifies the assertion surface (.EventTypeName) for all test code in both repos, not just the compliance suites.Non-breaking: DIMs only; existing store-specific members are unaffected (Marten's internal generic can later be retired independently).
Sequencing: not a hard blocker for P3.1 (the seam can call the
Type-based forms), but landing it before P3.3 extraction lets the shared sources use the generic forms directly.🤖 Generated with Claude Code