Changeset 12608
- Timestamp:
- 07/06/15 15:46:50 (9 years ago)
- Location:
- stable
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
stable
- Property svn:mergeinfo changed
/trunk/sources merged: 12490,12507,12518
- Property svn:mergeinfo changed
-
stable/HeuristicLab.ExtLibs
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.ExtLibs merged: 12490,12507,12518
- Property svn:mergeinfo changed
-
stable/HeuristicLab.ExtLibs/HeuristicLab.AvalonEdit/5.0.1/HeuristicLab.AvalonEdit-5.0.1/Plugin.cs.frame
r12009 r12608 27 27 [PluginFile("ICSharpCode.AvalonEdit.dll", PluginFileType.Assembly)] 28 28 [PluginFile("ICSharpCode.AvalonEdit License-5.0.1.txt", PluginFileType.License)] 29 [PluginDependency("HeuristicLab.NRefactory", "5.5")] 29 30 public class HeuristicLabAvalonEditPlugin : PluginBase { 30 31 } -
stable/HeuristicLab.ExtLibs/HeuristicLab.NRefactory/5.5.0/HeuristicLab.NRefactory-5.5.0/Plugin.cs.frame
r12009 r12608 30 30 [PluginFile("ICSharpCode.NRefactory.Xml.dll", PluginFileType.Assembly)] 31 31 [PluginFile("ICSharpCode.NRefactory License-5.5.0.txt", PluginFileType.License)] 32 [PluginDependency("HeuristicLab.Cecil", "0.9.5")] 32 33 public class HeuristicLabNRefactoryPlugin : PluginBase { 33 34 } -
stable/HeuristicLab.Tests
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Tests merged: 12518
- Property svn:mergeinfo changed
-
stable/HeuristicLab.Tests/HeuristicLab-3.3/PluginDependenciesTest.cs
r12009 r12608 60 60 foreach (Assembly pluginAssembly in loadedPlugins.Keys) { 61 61 Type plugin = loadedPlugins[pluginAssembly]; 62 var pluginFiles = new HashSet<string>(Attribute.GetCustomAttributes(plugin, false) 63 .OfType<PluginFileAttribute>().Where(pf => pf.FileType == PluginFileType.Assembly).Select(pf => pf.FileName)); 64 var pluginAssemblies = PluginLoader.Assemblies.Where(a => pluginFiles.Contains(Path.GetFileName(a.Location))).ToList(); 65 var referencedAssemblies = pluginAssemblies.SelectMany(a => a.GetReferencedAssemblies()).ToList(); 66 62 67 Dictionary<string, PluginDependencyAttribute> pluginDependencies = Attribute.GetCustomAttributes(plugin, false).OfType<PluginDependencyAttribute>().ToDictionary(a => a.Dependency); 63 68 64 foreach (AssemblyName referencedAssemblyName in pluginAssembly.GetReferencedAssemblies()) {69 foreach (AssemblyName referencedAssemblyName in referencedAssemblies) { 65 70 if (IsPluginAssemblyName(referencedAssemblyName)) { 66 71 if (!pluginDependencies.ContainsKey(pluginNames[referencedAssemblyName.FullName])) … … 87 92 Type plugin = loadedPlugins[pluginAssembly]; 88 93 Dictionary<PluginDependencyAttribute, string> pluginDependencies = Attribute.GetCustomAttributes(plugin, false).OfType<PluginDependencyAttribute>().ToDictionary(a => a, a => a.Dependency); 94 var pluginFiles = new HashSet<string>(Attribute.GetCustomAttributes(plugin, false) 95 .OfType<PluginFileAttribute>().Where(pf => pf.FileType == PluginFileType.Assembly).Select(pf => pf.FileName)); 96 var pluginAssemblies = PluginLoader.Assemblies.Where(a => pluginFiles.Contains(Path.GetFileName(a.Location))).ToList(); 97 var referencedAssemblies = pluginAssemblies.SelectMany(a => a.GetReferencedAssemblies()).ToList(); 89 98 90 99 foreach (PluginDependencyAttribute attribute in pluginDependencies.Keys) { … … 93 102 if (pluginDependencyName == "HeuristicLab.MathJax") continue; //is never referenced as this plugin contains HTML files 94 103 if (pluginDependencyName == "HeuristicLab.MatlabConnector") continue; //the matlab connector is loaded dynamically and hence not referenced by the dll 95 var referencedPluginAssemblies = pluginAssembly.GetReferencedAssemblies().Where(IsPluginAssemblyName);104 var referencedPluginAssemblies = referencedAssemblies.Where(IsPluginAssemblyName); 96 105 if (referencedPluginAssemblies.Any(a => pluginNames[a.FullName] == pluginDependencyName)) continue; 97 106 98 var referencedNonPluginAssemblies = pluginAssembly.GetReferencedAssemblies().Where(a => !IsPluginAssemblyName(a));107 var referencedNonPluginAssemblies = referencedAssemblies.Where(a => !IsPluginAssemblyName(a)); 99 108 bool found = (from referencedNonPluginAssembly in referencedNonPluginAssemblies 100 109 select referencedNonPluginAssembly.Name into assemblyName
Note: See TracChangeset
for help on using the changeset viewer.