Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ ReadElementContentAsBinHex()

override int System.Xml.XmlSubtreeReader.ReadElementContentAsBinHex ( byte[] buffer,
int index,
int count )
inlinevirtual

Reimplemented from System.Xml.XmlReader.

Definition at line 965 of file XmlSubtreeReader.cs.

966 {
967 switch (_state)
968 {
969 case State.Initial:
970 case State.Error:
971 case State.EndOfFile:
972 case State.Closed:
973 return 0;
974 case State.Interactive:
975 case State.PopNamespaceScope:
976 case State.ClearNsAttributes:
977 if (!InitReadElementContentAsBinary(State.ReadElementContentAsBinHex))
978 {
979 return 0;
980 }
981 goto case State.ReadElementContentAsBinHex;
982 case State.ReadElementContentAsBinHex:
983 {
985 if (num > 0 || count == 0)
986 {
987 return num;
988 }
989 if (NodeType != XmlNodeType.EndElement)
990 {
991 throw new XmlException(System.SR.Xml_InvalidNodeType, reader.NodeType.ToString(), reader as IXmlLineInfo);
992 }
993 _state = State.Interactive;
996 {
997 _state = State.EndOfFile;
998 SetEmptyNode();
999 }
1000 else
1001 {
1002 Read();
1003 }
1004 return 0;
1005 }
1006 case State.ReadElementContentAsBase64:
1007 case State.ReadContentAsBase64:
1008 case State.ReadContentAsBinHex:
1010 default:
1011 return 0;
1012 }
1013 }
static string Xml_InvalidNodeType
Definition SR.cs:88
static string Xml_MixingBinaryContentMethods
Definition SR.cs:184
Definition SR.cs:7
virtual int ReadContentAsBinHex(byte[] buffer, int index, int count)
Definition XmlReader.cs:554
XmlNodeType NodeType
Definition XmlReader.cs:62
bool InitReadElementContentAsBinary(State binaryState)
override XmlNodeType NodeType

References System.Xml.XmlSubtreeReader._initialDepth, System.Xml.XmlSubtreeReader._state, System.buffer, System.count, System.Xml.XmlReader.Depth, System.index, System.Xml.XmlSubtreeReader.InitReadElementContentAsBinary(), System.Xml.XmlReader.NodeType, System.Xml.XmlSubtreeReader.NodeType, System.Xml.XmlSubtreeReader.ProcessNamespaces(), System.Xml.XmlSubtreeReader.Read(), System.Xml.XmlReader.ReadContentAsBinHex(), System.Xml.XmlWrappingReader.reader, System.Xml.XmlSubtreeReader.SetEmptyNode(), System.SR.Xml_InvalidNodeType, System.SR.Xml_MixingBinaryContentMethods, and System.Xml.XmlException.