ResolveTypes() публичный Метод

Resolves all instances of the type registered on the service.
Note that the actual implementation lays in the hands of the IoC technique being used.
The is null.
public ResolveTypes ( Type serviceType ) : IEnumerable
serviceType System.Type The type of the service.
Результат IEnumerable
Пример #1
0
 public void ReturnsAllAvaliableInstances()
 {
     var serviceLocator = new ServiceLocator { AutoRegisterTypesViaAttributes = true };
     serviceLocator.RegisterInstance(typeof(IFooService), new FooService2(), "FooService3");
     Assert.AreEqual(3, serviceLocator.ResolveTypes<IFooService>().Count());
 }