public static string VerifyPublicId(string publicId) { if (publicId == null) { throw new ArgumentNullException("publicId"); } if (XmlChar.IsPubid(publicId)) { return(publicId); } throw new XmlException(string.Format("'{0}' is not a valid PUBLIC ID", publicId)); }