public string [] GetOutputFolders(string [] productCodes, string culture, string fallbackCulture,
                                   ComponentsLocation componentsLocation)
 {
     throw new NotImplementedException();
 }
示例#2
0
		public string [] GetOutputFolders (string [] productCodes, string culture, string fallbackCulture,
						   ComponentsLocation componentsLocation)
		{
			throw new NotImplementedException ();
		}
示例#3
0
 public string[] GetOutputFolders(string[] productCodes, string culture, string fallbackCulture, ComponentsLocation componentsLocation)
 {
 }
	public string[] GetOutputFolders(string[] productCodes, string culture, string fallbackCulture, ComponentsLocation componentsLocation) {}
示例#5
0
        /// <summary>
        /// Returns the directories bootstrapper component files would be copied to when built given the specified settings
        /// </summary>
        /// <param name="productCodes">The productCodes of the selected components</param>
        /// <param name="culture">The culture used to build the bootstrapper</param>
        /// <param name="fallbackCulture">The fallback culture used to build the bootstrapper</param>
        /// <param name="componentsLocation">How the bootstrapper would package the selected components</param>
        /// <returns></returns>
        public string[] GetOutputFolders(string[] productCodes, string culture, string fallbackCulture, ComponentsLocation componentsLocation)
        {
            if (!_fInitialized)
            {
                Refresh();
            }

            Hashtable folders = new Hashtable();
            BuildSettings settings = new BuildSettings();
            string invariantPath = PackagePath.ToLowerInvariant();
            invariantPath = Util.AddTrailingChar(invariantPath, System.IO.Path.DirectorySeparatorChar);
            settings.CopyComponents = false;
            settings.Culture = culture;
            settings.FallbackCulture = fallbackCulture;
            settings.ComponentsLocation = componentsLocation;
            if (String.IsNullOrEmpty(settings.Culture) || settings.Culture == "*")
            {
                settings.Culture = settings.FallbackCulture;
            }

            foreach (string productCode in productCodes)
            {
                Product product = Products.Product(productCode);
                if (product == null)
                    continue;
                settings.ProductBuilders.Add(product.ProductBuilder);
            }
            ArrayList files = new ArrayList();

            BuildPackages(settings, null, null, files, null);

            foreach (string file in files)
            {
                string folder = System.IO.Path.GetDirectoryName(file);
                if (folder.Substring(0, invariantPath.Length).ToLowerInvariant().CompareTo(invariantPath) == 0)
                {
                    string relPath = folder.Substring(invariantPath.Length).ToLowerInvariant();
                    if (!folders.Contains(relPath))
                        folders.Add(relPath, relPath);
                }
            }

            ArrayList list = new ArrayList(folders.Values);
            string[] a = new string[list.Count];
            list.CopyTo(a, 0);
            return a;
        }
 public string[] GetOutputFolders(string[] productCodes, string culture, string fallbackCulture, ComponentsLocation componentsLocation)
 {
     if (!this.fInitialized)
     {
         this.Refresh();
     }
     Hashtable hashtable = new Hashtable();
     BuildSettings settings = new BuildSettings();
     string strB = Util.AddTrailingChar(this.PackagePath.ToLowerInvariant(), System.IO.Path.DirectorySeparatorChar);
     settings.CopyComponents = false;
     settings.Culture = culture;
     settings.FallbackCulture = fallbackCulture;
     settings.ComponentsLocation = componentsLocation;
     foreach (string str2 in productCodes)
     {
         Product product = this.Products.Product(str2);
         if (product != null)
         {
             settings.ProductBuilders.Add(product.ProductBuilder);
         }
     }
     ArrayList filesCopied = new ArrayList();
     this.BuildPackages(settings, null, null, filesCopied, null);
     foreach (string str3 in filesCopied)
     {
         string directoryName = System.IO.Path.GetDirectoryName(str3);
         if (directoryName.Substring(0, strB.Length).ToLowerInvariant().CompareTo(strB) == 0)
         {
             string key = directoryName.Substring(strB.Length).ToLowerInvariant();
             if (!hashtable.Contains(key))
             {
                 hashtable.Add(key, key);
             }
         }
     }
     ArrayList list2 = new ArrayList(hashtable.Values);
     string[] array = new string[list2.Count];
     list2.CopyTo(array, 0);
     return array;
 }