private string ParseEntityName()
{
int endPos;
try
{
endPos = ParseName();
}
catch (XmlException)
{
Throw(SR.Xml_ErrorParsingEntityName);
return null;
}
// check ';'
if (_ps.chars[endPos] != ';')
{
Throw(SR.Xml_ErrorParsingEntityName);
}
string entityName = _nameTable.Add(_ps.chars, _ps.charPos, endPos - _ps.charPos);
_ps.charPos = endPos + 1;
return entityName;
}