import { Type , getType } from "tst-reflect" ; export class ServiceCollection { get services ( ) : IterableIterator < [ Type , Array < Type > ] > { return this . _services . entries ( ) ; } /**
     * List of added dependencies
     */ private readonly _services : Map < Type , Array < Type > > = new Map < Type , Array < Type > > ( ) ; param dependencyType param dependencyImplementation addTransient < TDependency , TImplementation > ( dependencyType ? , dependencyImplementation ? ) { if ( dependencyType === undefined ) { dependencyType = getType < TDependency > ( ) ; } if ( dependencyImplementation === undefined ) { dependencyImplementation = getType < TImplementation > ( ) ; } const value = ( this . _services . get ( dependencyType ) || [ ] ) ; value . push ( dependencyImplementation ) ; this . _services . set ( dependencyType , value ) ; } }