/// <summary> /// This allows parsing the X and Y values from a string version of the extent as: /// 'X[-180|180], Y[-90|90]' Where minimum always precedes maximum. The correct /// M or MZ version of extent will be returned if the string has those values. /// </summary> /// <param name="text">The string text to parse.</param> public static Extent Parse(string text) { Extent result; string fail; if (TryParse(text, out result, out fail)) { return(result); } ExtentParseException ep = new ExtentParseException(String.Format("Attempting to read an extent string failed while reading the {0} term.", fail)); ep.Expression = text; throw ep; }
/// <summary> /// This allows parsing the X and Y values from a string version of the extent as: /// 'X[-180|180], Y[-90|90]' Where minimum always precedes maximum. The correct /// M or MZ version of extent will be returned if the string has those values. /// </summary> /// <param name="text">The string text to parse.</param> public static Extent Parse(string text) { Extent result; string fail; if (TryParse(text, out result, out fail)) return result; var ep = new ExtentParseException(String.Format("Attempting to read an extent string failed while reading the {0} term.", fail)) { Expression = text }; throw ep; }