Exemplo n.º 1
0
        public void AddPublicAssemblies(List <string> assemblies)
        {
            var publicAssemblies     = _pluginConfig.Items.OfType <PluginConfigPublicAssemblies>().FirstOrDefault();
            var listPublicAssemblies = new List <PluginConfigPublicAssembliesPublicAssembly>(publicAssemblies.PublicAssembly);

            foreach (var assembly in assemblies)
            {
                Version version           = GetAssemblyVersion(assembly);
                var     newPublicAssembly = new PluginConfigPublicAssembliesPublicAssembly
                {
                    name    = assembly,
                    version = string.Format("{0}.{1}", version.Major, version.Minor)
                };
                listPublicAssemblies.Add(newPublicAssembly);
            }
            publicAssemblies.PublicAssembly = listPublicAssemblies.ToArray();
        }
Exemplo n.º 2
0
        public void AddPublicAssemblies(List<string> assemblies)
        {
            var publicAssemblies = _pluginConfig.Items.OfType<PluginConfigPublicAssemblies>().FirstOrDefault();
            var listPublicAssemblies = new List<PluginConfigPublicAssembliesPublicAssembly>(publicAssemblies.PublicAssembly);

            foreach (var assembly in assemblies)
            {
                Version version = GetAssemblyVersion(assembly);
                var newPublicAssembly = new PluginConfigPublicAssembliesPublicAssembly
                {
                    name = assembly,
                    version = string.Format("{0}.{1}", version.Major, version.Minor)
                };
                listPublicAssemblies.Add(newPublicAssembly);
                
            }
            publicAssemblies.PublicAssembly = listPublicAssemblies.ToArray();
        }