public void RegisterImplementationOf <TInterface>(TInterface component, string key) where TInterface : class { AutofacBuilder.RegisterInstance(component).Keyed <TInterface>(key).ExternallyOwned(); }