protected double parseDouble(double defValue, XElement parent, string key, bool required = false) { var nrm = parent.Attribute(key); if (nrm == null) { if (required) { throw new GeomPadException(); } return(defValue); } return(StaticHelpers.ParseDouble(nrm.Value)); }