public void LoadAssemblies(string[] searchAssemblies, string[] dependencies) { WorkerAppDomain.RemoteProxy.LoadAssemblies(dependencies, false); WorkerAppDomain.RemoteProxy.LoadAssemblies(searchAssemblies, true); try { AssemblyScanner.GetSearchAssemblyTypes(); } catch (TypeLoadException ex) { throw new PipelineException(string.Format(CultureInfo.CurrentCulture, Resources.CantLoadPipelineAssembly, new object[] { ex.TypeName })); } this.VerifyVersionOfReferenceAssemblies(); }
public IEnumerator <Type> GetEnumerator() { IEnumerable <Type> enumerable; if (WorkerAppDomain.InsideWorkerDomain) { enumerable = AssemblyScanner.GetSearchAssemblyTypes(); } else { enumerable = this.GetAllLoadedTypes(); } foreach (Type current in enumerable) { try { if (!current.IsDefined(this.attributeType, false)) { continue; } if (!this.IsSuitableType(current)) { throw new Exception("Resources.TypeScannerError"); } } catch (Exception obj) { if (this.customErrorHandler != null) { this.customErrorHandler(obj); continue; } throw; } yield return(current); } yield break; }