public IUnityContainer ConfigureContainer(SolrServerElement solrServer, IUnityContainer container, IReadOnlyMappingManager mappingManager)
And of course each SolrServerElement would need his own UnityContainer then, not one for all as the design now suggests.
(if I get all of this right...)
Would this be an acceptable way or should I reconfigure the containers with my MappingManagers after getting them configured
with AttributesMappingManager first? If the 2nd would be preferrable, could you point out how you would do this?
Sorry for all of these questions...
Thank you,
Markus
private static Lazy<IUnityContainer> container = new Lazy<IUnityContainer>(() =>
{
var container = new UnityContainer();
RegisterTypes(container);
return container;
});
public static IUnityContainer GetConfiguredContainer()
{
return container.Value;
}
public static void RegisterTypes(IUnityContainer container)
{
container.RegisterType<INewsReader, NewsReader>();
}
Any help is greatly appreciated
Thanks