예제 #1
0
        protected void RegisterInstance(Type serviceType, object instance)
        {
            var registryInstance = new RegistryInstance(serviceType, instance);

            registryInstance.Singleton();
            instances.Add(registryInstance);
        }
예제 #2
0
        protected ILifeCycleConfiguration Register(Type serviceType, Type implementationType, string serviceName = null)
        {
            var registryInstance = new RegistryInstance(serviceType, implementationType, serviceName);

            instances.Add(registryInstance);
            return(registryInstance);
        }