Esempio n. 1
0
        } // constructor

        public ServiceLogoMappings(string domainMappingsXmlFilename, string serviceMappingsXmlFile)
        {
            var domainMappings  = LogosCommon.ParseDomainMappingsXml(domainMappingsXmlFilename);
            var serviceMappings = LogosCommon.ParseServiceMappingsXml(serviceMappingsXmlFile);

            Init(domainMappings, serviceMappings);
        } // constructor
Esempio n. 2
0
        }     // VerifyLogosFiles

        private IEnumerable <Domain> GetReferencedFiles()
        {
            IDictionary <string, Domain> result;

            var serviceMappings = LogosCommon.ParseServiceMappingsXml(AppUiConfiguration.Current.Folders.Logos.FileServiceMappings);

            var domains = from package in serviceMappings.Packages
                          from domain in package.Domains
                          select domain;

            result = new Dictionary <string, Domain>(domains.Count());

            foreach (var domain in domains)
            {
                var domainName = domain.RedirectDomainName ?? domain.DomainName;
                result[domainName] = new Domain(domainName);
            } // foreach domain

            foreach (var domain in domains)
            {
                var domainName = domain.RedirectDomainName ?? domain.DomainName;
                var list       = result[domainName];

                foreach (var mapping in domain.Mappings)
                {
                    list.Add(mapping);
                } // foreach mapping
            }     // foreach domain

            return(result.Values);
        } // GetReferencedFiles
Esempio n. 3
0
        } // Run

        private IEnumerable <Domain> GetMappings()
        {
            var serviceMappings = LogosCommon.ParseServiceMappingsXml(AppUiConfiguration.Current.Folders.Logos.FileServiceMappings);

            var result = from package in serviceMappings.Packages
                         from domain in package.Domains
                         select new Domain(domain.RedirectDomainName ?? domain.DomainName, domain.Mappings);

            return(result);
        } // GetMappings
Esempio n. 4
0
        } // GetDomainMappings

        protected IDictionary <string, MappedService> GetMappedServices()
        {
            var serviceMappings = LogosCommon.ParseServiceMappingsXml(AppUiConfiguration.Current.Folders.Logos.FileServiceMappings);

            var q = from package in serviceMappings.Packages
                    where package.PackageName != "<default>"
                    from domain in package.Domains
                    from mapping in domain.Mappings
                    select new MappedService()
            {
                Domain = domain.DomainName, Mapping = mapping
            };

            var result = new Dictionary <string, MappedService>();

            foreach (var item in q)
            {
                result.Add(item.GetKey(), item);
            } // foreach

            return(result);
        } // GetMappedServices
Esempio n. 5
0
        } // GetBroadcastList

        protected IDictionary <string, ServiceLogoMappings.ReplacementDomain> GetDomainMappings()
        {
            var xmlMappings = LogosCommon.ParseDomainMappingsXml(AppUiConfiguration.Current.Folders.Logos.FileServiceDomainMappings);

            return(ServiceLogoMappings.BuildMapping(xmlMappings));
        } // GetDomainMappings
Esempio n. 6
0
        } // constructor

        public ProviderLogoMappings(string providerMappingsXmlFilename)
        {
            var providerMappings = LogosCommon.ParseProviderMappingsXml(providerMappingsXmlFilename);

            Init(providerMappings);
        } // constructor