internal static Exception CreateInvalidCharException(char invChar, char nextChar, ExceptionType exceptionType)
 {
     return(CreateException(SR.Xml_InvalidCharacter, XmlException.BuildCharExceptionArgs(invChar, nextChar), exceptionType));
 }
 internal static Exception CreateInvalidNameCharException(string name, int index, ExceptionType exceptionType)
 {
     return(CreateException(index == 0 ? SR.Xml_BadStartNameChar : SR.Xml_BadNameChar, XmlException.BuildCharExceptionArgs(name, index), exceptionType, 0, index + 1));
 }
 internal static Exception CreateInvalidCharException(string data, int invCharPos, ExceptionType exceptionType)
 {
     return(CreateException(SR.Xml_InvalidCharacter, XmlException.BuildCharExceptionArgs(data, invCharPos), exceptionType, 0, invCharPos + 1));
 }