register<T> method

void register<T>(
  1. Spec spec,
  2. Factory<T> factory
)

Implementation

void register<T>(Spec spec, Factory<T> factory) =>
    _registry.putIfAbsent(spec, () => {}).add(factory);