private static FoldingDesc ParseFolding(XmlNode foldingNode) { FoldingDesc folding = new FoldingDesc(); //regex folding.startMarkerRegex = foldingNode.Attributes["start"].Value; folding.finishMarkerRegex = foldingNode.Attributes["finish"].Value; //options var optionsA = foldingNode.Attributes["options"]; if (optionsA != null) { folding.options = (RegexOptions)Enum.Parse(typeof(RegexOptions), optionsA.Value); } return(folding); }
private static FoldingDesc ParseFolding(XmlNode foldingNode) { FoldingDesc folding = new FoldingDesc(); //regex folding.startMarkerRegex = foldingNode.Attributes["start"].Value; folding.finishMarkerRegex = foldingNode.Attributes["finish"].Value; //options var optionsA = foldingNode.Attributes["options"]; if (optionsA != null) folding.options = (RegexOptions)Enum.Parse(typeof(RegexOptions), optionsA.Value); return folding; }