private static IDependencyConfig InitializeContainer(ExtensionConfigContext context) { var configType = context.Config.TypeLocator.GetTypes() .Where(x => typeof(IDependencyConfig).IsAssignableFrom(x) && !x.IsInterface && !x.IsAbstract) .FirstOrDefault(); IDependencyConfig dependencyConfig = null; if (configType != null) { var configInstance = Activator.CreateInstance(configType); dependencyConfig = (IDependencyConfig)configInstance; } return(dependencyConfig); }
public void TestInitialize() => _dependencyConfig = new DependencyConfig();
public DependencyInjection(IDependencyConfig config) { _config = config; }
public DependencyProvider(IDependencyConfig dependencyConfig) { _dependencyConfig = dependencyConfig; _recursionExcludTypes = new ConcurrentDictionary <int, Stack <Type> >(); }