public ReferenceBundle(ProjectReference parent, ProjectReference reference) { Parent = parent; Reference = reference; }
private List<BaseReference> MakeDependencyList(ProjectReference projectReference) { List<BaseReference> list; if (!_dependencies.TryGetValue(projectReference, out list)) { list = new List<BaseReference>(); _dependencies.Add(projectReference, list); } return list; }
private void AddParentDependency(ProjectReference parent, ProjectReference projectReference) { string assemblyName = projectReference.DisplayName; var excludeFilters = parent == null ? ExcludeRegex : ExcludeProjectReferencesRegex; if (!IsApplicable(excludeFilters, assemblyName)) return; MakeDependencyList(projectReference); if (parent != null) AddDependency(parent, projectReference); }
private void AddDependency(ProjectReference projectReference, BaseReference baseReference) { var list = MakeDependencyList(projectReference); list.Add(baseReference); }
private void Process(ProjectReference parent, ProjectReference projectReference, Stack<ReferenceBundle> processStack) { ProjectReference existProject; if (_storage.TryGetValue(projectReference.Include, out existProject)) { AddParentDependency(parent, existProject); return; } _storage.Add(projectReference.Include, projectReference); var parser = CreateParser(projectReference.Include); projectReference.Update(parser); AddParentDependency(parent, projectReference); var applicableReferences = parser .GetAssemblyReferences() .Where(reference => IsApplicable(ExcludeReferencesRegex, reference.DisplayName)); foreach (var reference in applicableReferences) AddDependency(projectReference, reference); foreach (var reference in parser.GetProjectReferences()) { reference.UpdateInclude(projectReference.Include); processStack.Push(new ReferenceBundle(projectReference, reference)); } }