public void LoadAssemblies(string[] directories) { if (!ChoGuard.IsArgumentNotNullOrEmpty(directories)) { return; } foreach (Assembly assembly in ChoAssembly.GetAssemblies(directories)) { if (_loadedAssemblies.ContainsKey(assembly.FullName)) { continue; } _loadedAssemblies.Add(assembly.FullName, assembly); } }
public void LoadAssemblies(string[] directories) { if (!ChoGuard.IsArgumentNotNullOrEmpty(directories)) { return; } lock (_padLock) { foreach (Assembly assembly in ChoAssembly.GetAssemblies(directories)) { if (_loadedAssemblies.ContainsKey(assembly.FullName)) { continue; } _loadedAssemblies.Add(assembly.FullName, assembly); AssemblyLoaded.Raise(null, new ChoEventArgs <Assembly>(assembly)); } } }