public static filter indexPartFilter(bool isJS, servConfig.Apps app, servConfig.SkinIds skin, servConfig.Brands brand, Langs lang, bool isMin) { return new filter { apps = new servConfig.Apps[] { app }, langs = new Langs[] { lang }, allBrendMasks = new string[] { isJS ? brendJSMask : brendCSSMask }, allSkinMasks = new string[] { isJS ? skinJSMask : skinCSSMask }, allBrands = new string[] { brand.ToString() }, allSkins = new string[] { skin.ToString() }, allFixs = isJS ? (!isMin ? new string[] { "js", "js{loc}" } : new string[] { "jsmin", "js{loc}min" }) : (!isMin ? new string[] { "css" } : new string[] { "cssmin" }) }; }
static IEnumerable<string> existedDpls(servConfig.Apps app, IEnumerable<string> names, string mask) { //dej dpl urls, ktere skutecne existuji return names.Select(n => dplUrl(app, n, mask)).Where(url => File.Exists(pathFromUrl(url))); }
//static string dplPath(servConfig.Apps app, string name, string mask) { return string.Format(@"{0}\deploy\{1}\{2}.dpl.json", commonDir, app, mask == null ? name : string.Format(mask, name)); } static string dplUrl(servConfig.Apps app, string name, string mask) { return string.Format(@"/deploy/{0}/{1}.dpl.json", app, mask == null ? name : string.Format(mask, name)); }