public IEnumerable <IHtmlSchemaFileInfo> GetSchemas(string defaultSchemaPath)
 {
     foreach (string file in Directory.EnumerateFiles(GetSchemaFolder(), "*.xsd"))
     {
         yield return(HtmlSchemaFileInfo.FromFile(file));
     }
 }
		public static HtmlSchemaFileInfo FromFile(string file)
		{
			HtmlSchemaFileInfo info = new HtmlSchemaFileInfo();
			info.File = file;

			string input = System.IO.File.ReadAllText(file);
			Match match = _regex.Match(input);

			if (match.Success)
			{
				info.CustomPrefix = match.Groups["prefix"].Value;
			}

			return info;
		}
Example #3
0
        public static HtmlSchemaFileInfo FromFile(string file)
        {
            HtmlSchemaFileInfo info = new HtmlSchemaFileInfo();

            info.File = file;

            string input = System.IO.File.ReadAllText(file);
            Match  match = _regex.Match(input);

            if (match.Success)
            {
                info.CustomPrefix = match.Groups["prefix"].Value;
            }

            return(info);
        }