Exemple #1
0
		public RegionsExtractor GetExtractor(string file, string langId, string code = null)
		{
			var extractor = Extractors.FirstOrDefault(regionsExtractor => regionsExtractor.file == file && regionsExtractor.langId == langId);
			if (extractor != null)
				return extractor;

			if (code == null)
				code = Dir.GetContent(file);
			extractor = new RegionsExtractor(code, langId, file);
			Extractors.Add(extractor);
			return extractor;
		}
Exemple #2
0
        public RegionsExtractor GetExtractor(string file, string langId, string code = null)
        {
            var extractor = Extractors.FirstOrDefault(regionsExtractor => regionsExtractor.file == file && regionsExtractor.langId == langId);

            if (extractor != null)
            {
                return(extractor);
            }

            if (code == null)
            {
                code = Dir.GetContent(file);
            }
            extractor = new RegionsExtractor(code, langId, file);
            Extractors.Add(extractor);
            return(extractor);
        }