38 writes to curNode
System.Xml (38)
System\Xml\Core\XmlTextReaderImpl.cs (28)
342
curNode
= new NodeData();
372
curNode
= nodes[0];
435
curNode
= nodes[0];
1052
curNode
= nodes[i];
1068
curNode
= nodes[i];
1089
curNode
= nodes[index + 1 + curAttrIndex];
1103
curNode
= nodes[index + 1];
1114
curNode
= nodes[ index + 1 + ++curAttrIndex ];
1129
curNode
= nodes[index];
1189
curNode
= nodes[index];
1195
curNode
= AddNode( index, index );
1205
curNode
= nodes[index];
1222
curNode
= AddNode( index, index );
1228
curNode
= AddNode( index, index );
1238
curNode
= nodes[index];
1292
curNode
= nodes[index];
1382
curNode
= simpleValueNode;
1387
curNode
= curNode.nextAttrValueChunk;
1411
curNode
= curNode.nextAttrValueChunk;
2011
curNode
= nodes[0];
2317
curNode
= AddNode( index + attrCount + 1, index );
2321
curNode
= originalCurNode;
3256
curNode
= NodeData.None;
4223
curNode
= nodes[index];
5618
curNode
= nodes[index];
5629
curNode
= nodes[index + attrCount + 1];
6991
curNode
= nodes[0];
7690
curNode
= AddNode( index + attrCount + 1, index + 2 );
System\Xml\Core\XmlTextReaderImplAsync.cs (10)
173
curNode
= nodes[index];
179
curNode
= AddNode(index, index);
189
curNode
= nodes[index];
205
curNode
= AddNode(index, index);
211
curNode
= AddNode(index, index);
221
curNode
= nodes[index];
296
curNode
= nodes[index];
735
curNode
= AddNode( index + attrCount + 1, index );
739
curNode
= originalCurNode;
2082
curNode
= nodes[index];
259 references to curNode
System.Xml (259)
System\Xml\Core\XmlTextReaderImpl.cs (171)
455
curNode
.SetLineInfo( ps.LineNo - 1, ps.LinePos - 1 );
871
return
curNode
.type;
878
return
curNode
.GetNameWPrefix( nameTable );
885
return
curNode
.localName;
892
return
curNode
.ns;
899
return
curNode
.prefix;
915
return
curNode
.StringValue;
922
return
curNode
.depth;
936
return
curNode
.IsEmptyElement;
943
return
curNode
.IsDefaultAttribute;
951
return
curNode
.type == XmlNodeType.Attribute ?
curNode
.quoteChar : '"';
1125
else if (
curNode
.type != XmlNodeType.Attribute ) {
1206
Debug.Assert(
curNode
.type == XmlNodeType.Element );
1207
curNode
.IsEmptyElement = false;
1229
curNode
.SetValueNode( XmlNodeType.Text, string.Empty );
1230
curNode
.SetLineInfo( ps.lineNo, ps.LinePos );
1319
switch (
curNode
.type ) {
1322
if (
curNode
.IsEmptyElement ) {
1329
Debug.Assert(
curNode
.type == XmlNodeType.EndElement );
1354
if (
curNode
.type != XmlNodeType.Attribute ) {
1377
if (
curNode
.nextAttrValueChunk == null || entityHandling == EntityHandling.ExpandEntities ) {
1378
NodeData simpleValueNode = AddNode( index + attrCount + 1,
curNode
.depth + 1 );
1379
simpleValueNode.SetValueNode( XmlNodeType.Text,
curNode
.StringValue );
1380
simpleValueNode.lineInfo =
curNode
.lineInfo2;
1381
simpleValueNode.depth =
curNode
.depth + 1;
1387
curNode =
curNode
.nextAttrValueChunk;
1395
nodes[index + attrCount + 1] =
curNode
;
1410
if (
curNode
.nextAttrValueChunk != null ) {
1411
curNode =
curNode
.nextAttrValueChunk;
1412
nodes[index + attrCount + 1] =
curNode
; // if curNode == EntityReference node, it will be picked from here by SetupEndEntityNodeInAttribute
1430
if (
curNode
.type != XmlNodeType.EntityReference ) {
1439
switch ( HandleGeneralEntityReference(
curNode
.localName, true, true,
curNode
.LinePos ) ) {
1456
switch ( HandleGeneralEntityReference(
curNode
.localName, false, true,
curNode
.LinePos ) ) {
1546
if ( !XmlReader.CanReadContentAs(
curNode
.type ) ) {
1594
if ( !XmlReader.CanReadContentAs(
curNode
.type ) ) {
1641
if (
curNode
.type != XmlNodeType.Element ) {
1689
if (
curNode
.type != XmlNodeType.Element ) {
1714
if ( !XmlReader.HasValueInternal(
curNode
.type ) ) {
1715
throw new InvalidOperationException( Res.GetString( Res.Xml_InvalidReadValueChunk,
curNode
.type ) ) ;
1754
int read =
curNode
.CopyTo( readValueOffset, buffer, index + readCount, count - readCount );
1773
curNode
.SetValue( string.Empty );
1807
curNode
.SetValue( ps.chars, startPos, endPos - startPos );
1822
return
curNode
.LineNo;
1829
return
curNode
.LinePos;
2012
curNode
.Clear( XmlNodeType.None );
2013
curNode
.SetLineInfo( 0, 0 );
2076
if (
curNode
.type != XmlNodeType.Element) {
2079
if (
curNode
.IsEmptyElement ) {
2106
if (
curNode
.type != XmlNodeType.Element) {
2109
if (
curNode
.IsEmptyElement ) {
2136
if (
curNode
.type != XmlNodeType.Element) {
2139
if (
curNode
.IsEmptyElement ) {
2315
NodeData originalCurNode =
curNode
;
2319
curNode
.CopyTo( 0, sb );
2499
curNode
.SetLineInfo( xmlEx.LineNumber, xmlEx.LinePosition );
3289
curNode
.SetLineInfo( ps.LineNo, ps.LinePos + 2 );
3290
curNode
.SetNamedNode( XmlNodeType.XmlDeclaration, Xml );
3317
curNode
.SetValue( sb.ToString() );
3699
if ( fragmentType == XmlNodeType.None &&
curNode
.type == XmlNodeType.Text ) {
3872
if ( index == 0 &&
curNode
.type != XmlNodeType.Element ) {
3901
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
3978
curNode
.SetNamedNode( XmlNodeType.Element,
3985
curNode
.SetNamedNode( XmlNodeType.Element,
3991
curNode
.SetNamedNode( XmlNodeType.Element,
3995
lastPrefix =
curNode
.prefix;
4032
curNode
.IsEmptyElement = true;
4057
Debug.Assert(
curNode
.type == XmlNodeType.Element );
4059
IDtdAttributeListInfo attlistInfo = dtdInfo.LookupAttributeList(
curNode
.localName,
curNode
.prefix );
4110
SendValidationEvent( XmlSeverityType.Error, Res.Sch_UnSpecifiedDefaultAttributeInExternalStandalone, qname,
curNode
.LineNo,
curNode
.LinePos );
4226
Debug.Assert(
curNode
== startTagNode );
4318
Debug.Assert(
curNode
.type == XmlNodeType.Element );
4325
Debug.Assert(
curNode
.type == XmlNodeType.Element );
4331
curNode
.IsEmptyElement = true;
4548
Debug.Assert(
curNode
.type == XmlNodeType.Element );
4549
if (
curNode
.prefix.Length == 0 ) {
4550
curNode
.ns = xmlContext.defaultNamespace;
4553
curNode
.ns = LookupNamespace(
curNode
);
4603
if ( !
curNode
.xmlContextPushed ) {
4626
if ( !
curNode
.xmlContextPushed ) {
4643
if ( !
curNode
.xmlContextPushed ) {
4938
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
4951
curNode
.SetValueNode( nodeType, ps.chars, startPos, endPos - startPos );
4976
curNode
.SetValueNode( nodeType, stringBuilder.ToString() );
4987
curNode
.SetValueNode( XmlNodeType.Text, ps.chars, startPos, endPos - startPos );
5015
curNode
.SetValueNode( nodeType, stringBuilder.ToString() );
5266
curNode
.CopyTo( readValueOffset, stringBuilder );
5277
curNode
.SetValue( stringBuilder.ToString() );
5293
curNode
.SetValue(
curNode
.StringValue.Substring( readValueOffset ) );
5307
curNode
.SetValue(
curNode
.StringValue.Substring( readValueOffset ) );
5312
curNode
.SetValue( string.Empty );
5366
if (
curNode
.type != XmlNodeType.EndElement ) {
5367
Throw( Res.Xml_InvalidNodeType,
curNode
.type.ToString() );
5385
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
5389
curNode
.SetValueNode( nodeType, stringBuilder.ToString() );
5411
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
5412
curNode
.SetNamedNode( XmlNodeType.EntityReference, ParseEntityName() );
5530
curNode
.entityId = ps.entityId;
5537
curNode
.entityId = ps.entityId;
5552
curNode
.entityId = ps.entityId;
5619
Debug.Assert(
curNode
.depth == index );
5620
curNode
.SetNamedNode( XmlNodeType.EndEntity, lastEntity.Name );
5621
curNode
.lineInfo.Set( ps.lineNo, ps.LinePos - 1 );
5630
Debug.Assert(
curNode
.type == XmlNodeType.EntityReference );
5631
Debug.Assert( Ref.Equal( lastEntity.Name,
curNode
.localName ) );
5632
curNode
.lineInfo.linePos +=
curNode
.localName.Length;
5633
curNode
.type = XmlNodeType.EndEntity;
5645
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
5661
curNode
.SetNamedNode( XmlNodeType.ProcessingInstruction, target );
5688
curNode
.SetValue( ps.chars, startPos, endPos - startPos );
5715
curNode
.SetValue( stringBuilder.ToString() );
5879
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
5882
curNode
.SetValueNode( type, ps.chars, startPos, endPos - startPos );
5889
curNode
.SetValueNode( type, stringBuilder.ToString() );
6073
curNode
.SetLineInfo(ps.LineNo, ps.LinePos);
6103
curNode
.SetNamedNode(XmlNodeType.DocumentType, dtdInfo.Name.ToString(), string.Empty, null);
6104
curNode
.SetValue(dtdInfo.InternalDtdSubset);
6188
curNode
.SetValue( string.Empty );
6979
if (
curNode
.xmlContextPushed ) {
6992
curNode
.Clear( XmlNodeType.None );
6993
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
7066
curNode
.xmlContextPushed = true;
7070
Debug.Assert(
curNode
.xmlContextPushed );
7072
curNode
.xmlContextPushed = false;
7250
curNode
.entityId = ps.entityId;
7337
curNode
.lineInfo = incReadLineInfo;
7523
if ( XmlConvert.StrEqual( chars, ps.charPos + 2, endPos - ps.charPos - 2,
curNode
.GetNameWPrefix( nameTable ) ) &&
7559
if ( XmlConvert.StrEqual( ps.chars, ps.charPos + 1, endPos - ps.charPos - 1,
curNode
.localName ) &&
7597
if ( chars[pos] ==
curNode
.quoteChar ) {
7602
curNode
.quoteChar = chars[pos];
7662
if (
curNode
.type == XmlNodeType.None ) {
7663
curNode
.type = XmlNodeType.Attribute;
7665
ParseAttributeValueSlow( ps.charPos, ' ',
curNode
); // The quote char is intentionally empty (space) because we need to parse ' and " into the attribute value
7691
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
7694
curNode
.SetValueNode( XmlNodeType.Text, string.Empty );
7749
curNode
.lineInfo.linePos++;
7751
curNode
.SetNamedNode( XmlNodeType.EntityReference, ParseEntityName() );
7816
curNode
.SetValueNode( XmlNodeType.Text, stringBuilder.ToString() );
7958
if ( !XmlReader.IsTextualNode(
curNode
.type ) ) {
7965
incReadLineInfo.Set(
curNode
.LineNo,
curNode
.LinePos );
7971
Debug.Assert(
curNode
.type == XmlNodeType.Element );
7973
bool isEmpty =
curNode
.IsEmptyElement;
7983
if (
curNode
.type != XmlNodeType.EndElement ) {
7984
Throw( Res.Xml_InvalidNodeType,
curNode
.type.ToString() );
7991
incReadLineInfo.Set(
curNode
.LineNo,
curNode
.LinePos );
7997
switch (
curNode
.type ) {
8148
Debug.Assert(
curNode
.type == XmlNodeType.Whitespace && newNodeType == XmlNodeType.SignificantWhitespace, "Incorrect node type change!" );
8149
curNode
.type = newNodeType;
8161
return
curNode
.schemaType;
8164
curNode
.schemaType = value;
8170
return
curNode
.typedValue;
8173
curNode
.typedValue = value;
8356
charsRead =
curNode
.CopyToBinary( incReadDecoder, readValueOffset );
8360
curNode
.AdjustLineInfo( readValueOffset, ps.eolNormalized, ref incReadLineInfo );
8371
curNode
.SetValue( string.Empty );
8397
curNode
.SetValue( ps.chars, startPos, endPos - startPos );
8400
curNode
.SetLineInfo( incReadLineInfo.lineNo, incReadLineInfo.linePos );
8417
incReadLineInfo.Set(
curNode
.LineNo,
curNode
.LinePos );
8431
if (
curNode
.type != XmlNodeType.EndElement ) {
8432
throw new XmlException( Res.Xml_InvalidNodeType,
curNode
.type.ToString(), this as IXmlLineInfo );
System\Xml\Core\XmlTextReaderImplAsync.cs (88)
42
return Task.FromResult(
curNode
.StringValue);
56
return
curNode
.StringValue;
190
Debug.Assert(
curNode
.type == XmlNodeType.Element);
191
curNode
.IsEmptyElement = false;
212
curNode
.SetValueNode(XmlNodeType.Text, string.Empty);
213
curNode
.SetLineInfo(ps.lineNo, ps.LinePos);
323
switch (
curNode
.type ) {
326
if (
curNode
.IsEmptyElement ) {
333
Debug.Assert(
curNode
.type == XmlNodeType.EndElement );
393
if ( !XmlReader.CanReadContentAs(
curNode
.type ) ) {
448
if ( !XmlReader.CanReadContentAs(
curNode
.type ) ) {
511
if (
curNode
.type != XmlNodeType.Element ) {
566
if (
curNode
.type != XmlNodeType.Element ) {
586
if ( !XmlReader.HasValueInternal(
curNode
.type ) ) {
587
throw new InvalidOperationException( Res.GetString( Res.Xml_InvalidReadValueChunk,
curNode
.type ) ) ;
626
int read =
curNode
.CopyTo( readValueOffset, buffer, index + readCount, count - readCount );
645
curNode
.SetValue( string.Empty );
685
curNode
.SetValue( ps.chars, startPos, endPos - startPos );
733
NodeData originalCurNode =
curNode
;
737
curNode
.CopyTo( 0, sb );
1121
curNode
.SetLineInfo( ps.LineNo, ps.LinePos + 2 );
1122
curNode
.SetNamedNode( XmlNodeType.XmlDeclaration, Xml );
1149
curNode
.SetValue( sb.ToString() );
1535
if (fragmentType == XmlNodeType.None &&
curNode
.type == XmlNodeType.Text) {
1551
if (fragmentType == XmlNodeType.None &&
curNode
.type == XmlNodeType.Text) {
1708
curNode
.SetLineInfo(ps.LineNo, ps.LinePos);
1812
curNode
.SetNamedNode(XmlNodeType.Element,
1819
curNode
.SetNamedNode(XmlNodeType.Element,
1825
curNode
.SetNamedNode(XmlNodeType.Element,
1829
lastPrefix =
curNode
.prefix;
1872
curNode
.IsEmptyElement = true;
2085
Debug.Assert(
curNode
== startTagNode);
2193
Debug.Assert(
curNode
.type == XmlNodeType.Element );
2200
Debug.Assert(
curNode
.type == XmlNodeType.Element );
2206
curNode
.IsEmptyElement = true;
2706
curNode
.SetLineInfo(ps.LineNo, ps.LinePos);
2733
curNode
.SetValueNode(nodeType, ps.chars, startPos, endPos - startPos);
2770
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
2791
curNode
.SetValueNode( nodeType, ps.chars, startPos, endPos - startPos );
2825
curNode
.SetValueNode( nodeType, stringBuilder.ToString() );
2836
curNode
.SetValueNode( XmlNodeType.Text, ps.chars, startPos, endPos - startPos );
2880
curNode
.SetValueNode( nodeType, stringBuilder.ToString() );
3291
curNode
.CopyTo( readValueOffset, stringBuilder );
3315
curNode
.SetValue( stringBuilder.ToString() );
3331
curNode
.SetValue(
curNode
.StringValue.Substring( readValueOffset ) );
3345
curNode
.SetValue(
curNode
.StringValue.Substring( readValueOffset ) );
3350
curNode
.SetValue( string.Empty );
3416
if (
curNode
.type != XmlNodeType.EndElement ) {
3417
Throw( Res.Xml_InvalidNodeType,
curNode
.type.ToString() );
3435
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
3439
curNode
.SetValueNode( nodeType, stringBuilder.ToString() );
3461
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
3462
curNode
.SetNamedNode( XmlNodeType.EntityReference, await ParseEntityNameAsync().ConfigureAwait(false) );
3597
curNode
.entityId = ps.entityId;
3604
curNode
.entityId = ps.entityId;
3619
curNode
.entityId = ps.entityId;
3636
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
3652
curNode
.SetNamedNode( XmlNodeType.ProcessingInstruction, target );
3685
curNode
.SetValue( ps.chars, startPos, endPos - startPos );
3728
curNode
.SetValue( stringBuilder.ToString() );
3900
curNode
.SetLineInfo( ps.LineNo, ps.LinePos );
3909
curNode
.SetValueNode( type, ps.chars, startPos, endPos - startPos );
3925
curNode
.SetValueNode( type, stringBuilder.ToString() );
4125
curNode
.SetLineInfo(ps.LineNo, ps.LinePos);
4155
curNode
.SetNamedNode(XmlNodeType.DocumentType, dtdInfo.Name.ToString(), string.Empty, null);
4156
curNode
.SetValue(dtdInfo.InternalDtdSubset);
4245
curNode
.SetValue( string.Empty );
4912
if ( !XmlReader.IsTextualNode(
curNode
.type ) ) {
4919
incReadLineInfo.Set(
curNode
.LineNo,
curNode
.LinePos );
4925
Debug.Assert(
curNode
.type == XmlNodeType.Element );
4927
bool isEmpty =
curNode
.IsEmptyElement;
4937
if (
curNode
.type != XmlNodeType.EndElement ) {
4938
Throw( Res.Xml_InvalidNodeType,
curNode
.type.ToString() );
4945
incReadLineInfo.Set(
curNode
.LineNo,
curNode
.LinePos );
4951
switch (
curNode
.type ) {
4991
charsRead =
curNode
.CopyToBinary( incReadDecoder, readValueOffset );
4995
curNode
.AdjustLineInfo( readValueOffset, ps.eolNormalized, ref incReadLineInfo );
5006
curNode
.SetValue( string.Empty );
5038
curNode
.SetValue( ps.chars, startPos, endPos - startPos );
5041
curNode
.SetLineInfo( incReadLineInfo.lineNo, incReadLineInfo.linePos );
5058
incReadLineInfo.Set(
curNode
.LineNo,
curNode
.LinePos );
5072
if (
curNode
.type != XmlNodeType.EndElement ) {
5073
throw new XmlException( Res.Xml_InvalidNodeType,
curNode
.type.ToString(), this as IXmlLineInfo );