protected override Registration CreateRegistrationCore <TService, TImplementation>(Container container) { TryEnableTransientDisposalOrThrow(container); var registration = new DisposableTransientLifestyleRegistration <TService, TImplementation>(this, container); registration.ScopedLifestyle = this.scopedLifestyle; return(registration); }
protected override Registration CreateRegistrationCore <TService>(Func <TService> instanceCreator, Container container) { TryEnableTransientDisposalOrThrow(container); var registration = new DisposableTransientLifestyleRegistration <TService>(this, container, instanceCreator); registration.ScopedLifestyle = this.scopedLifestyle; return(registration); }