1 write to dataReader
System.Data (1)
fx\src\data\System\Data\XmlDataLoader.cs (1)
564
dataReader
= DataTextReader.CreateReader(reader);
95 references to dataReader
System.Data (95)
fx\src\data\System\Data\XmlDataLoader.cs (95)
546
XmlNameTable nameTable =
dataReader
.NameTable;
566
int entryDepth =
dataReader
.Depth; // Store current XML element depth so we'll read
573
nodeToSchemaMap = isTableLevel ? new XmlToDatasetMap(
dataReader
.NameTable, dataTable) :
574
new XmlToDatasetMap(
dataReader
.NameTable, dataSet);
598
while( !
dataReader
.EOF ) { // Main XML parsing loop. Check for EOF just in case.
599
if (
dataReader
.Depth < entryDepth) // Stop if we have consumed all elements allowed
603
dataReader
.Read();
606
DataTable table = nodeToSchemaMap.GetTableForNode(
dataReader
, FIgnoreNamespace(
dataReader
));
611
dataReader
.Read(); // Not found? Read next element.
670
int entryDepth =
dataReader
.Depth - 1; // Store current reader depth so we know when to stop reading
706
while (entryDepth <
dataReader
.Depth ) {
707
switch (
dataReader
.NodeType) { // Process nodes based on type
709
object o = nodeToSchemaMap.GetColumnSchema(table,
dataReader
, FIgnoreNamespace(
dataReader
));
723
dataReader
.Read(); // Advance to next element.
746
dataReader
.Read(); // Continue to the next element.
757
textNodeValue =
dataReader
.ReadString();
770
dataReader
.Read(); // We don't process that, skip to the next element.
775
dataReader
.Read(); // Proceed to the next element.
829
int entryDepth =
dataReader
.Depth; // Store current reader depth so we know when to stop reading
848
for ( int i =
dataReader
.AttributeCount -1; i >= 0; --i) {
850
dataReader
.MoveToAttribute(i); // Get this attribute
852
c = nodeToSchemaMap.GetColumnSchema(table,
dataReader
, FIgnoreNamespace(
dataReader
)) as DataColumn;
858
foundColumns[c.Ordinal] = c.ConvertXmlToObject(
dataReader
.Value);
877
if (
dataReader
.NamespaceURI == Keywords.DFFNS ) {
878
switch (
dataReader
.LocalName) {
880
diffId =
dataReader
.Value; // Store ID
883
hasChanges =
dataReader
.Value; // Store value
886
hasErrors = (bool)Convert.ChangeType(
dataReader
.Value, typeof(bool), CultureInfo.InvariantCulture);
891
else if (
dataReader
.NamespaceURI == Keywords.MSDNS ) {
892
if (
dataReader
.LocalName == Keywords.ROWORDER ) {
894
rowOrder = (Int32)Convert.ChangeType(
dataReader
.Value, typeof(Int32), CultureInfo.InvariantCulture);
896
} else if (
dataReader
.LocalName.StartsWith("hidden", StringComparison.Ordinal)) {
898
c = collection[XmlConvert.DecodeName(
dataReader
.LocalName.Substring(6))];
905
foundColumns[c.Ordinal] = c.ConvertXmlToObject(
dataReader
.Value);
921
if (
dataReader
.Read() && entryDepth <
dataReader
.Depth) {
923
while ( entryDepth <
dataReader
.Depth ) { // Get out as soon as we've processed all nested nodes.
924
switch (
dataReader
.NodeType) { // Process nodes based on type
926
object o = nodeToSchemaMap.GetColumnSchema(table,
dataReader
, FIgnoreNamespace(
dataReader
));
938
dataReader
.Read(); // Advance to next element.
958
DataTable misplacedTable = nodeToSchemaMap.GetTableForNode(
dataReader
, FIgnoreNamespace(
dataReader
));
967
dataReader
.Read(); // Not a table? Try next element.
978
textNodeValue =
dataReader
.ReadString();
990
dataReader
.Read(); // We don't process that, skip to the next element.
995
dataReader
.Read(); // We're done here, proceed to the next element.
1084
int entryDepth =
dataReader
.Depth; // Store depth so we won't read too much
1086
if (
dataReader
.AttributeCount > 0) // If have attributes
1087
xsiNilString =
dataReader
.GetAttribute(Keywords.XSI_NIL, Keywords.XSINS);
1098
if (
dataReader
.AttributeCount > 0) { // If have attributes, get attributes we'll need
1099
xsiTypeString =
dataReader
.GetAttribute(Keywords.TYPE, Keywords.XSINS);
1100
typeName =
dataReader
.GetAttribute(Keywords.MSD_INSTANCETYPE, Keywords.MSDNS);
1123
if ( !
dataReader
.IsEmptyElement ) // In case element is not empty
1124
while (
dataReader
.Read() && (entryDepth <
dataReader
.Depth));
1126
dataReader
.Read(); // And start reading next element.
1133
dataReader
.Read(); // if UDT is wrapped, skip the wrapper
1139
xmlAttrib = new XmlRootAttribute(
dataReader
.LocalName);
1140
xmlAttrib.Namespace =
dataReader
.NamespaceURI ;
1148
columnValue = column.ConvertXmlToObject(
dataReader
, xmlAttrib);
1151
dataReader
.Read(); // if Wrapper is skipped, skip its end tag
1159
if (
dataReader
.Read() && entryDepth <
dataReader
.Depth) {
1161
while (entryDepth <
dataReader
.Depth) {
1162
switch (
dataReader
.NodeType) { // Process nodes based on type
1169
text =
dataReader
.Value; // Get value.
1173
while (
dataReader
.Read() && entryDepth <
dataReader
.Depth && IsTextLikeNode(
dataReader
.NodeType)) {
1177
builder.Append(
dataReader
.Value); // Concatenate other sequential text like
1188
dataReader
.ReadString(); // We've got column value already. Read this one and ignore it.
1200
object o = nodeToSchemaMap.GetColumnSchema(column.Table,
dataReader
, FIgnoreNamespace(
dataReader
));
1214
dataReader
.Read(); // Already loaded, proceed to the next element
1228
DataTable misplacedTable = nodeToSchemaMap.GetTableForNode(
dataReader
, FIgnoreNamespace(
dataReader
));
1237
dataReader
.Read(); // No match? Try next element
1246
dataReader
.Read(); // We don't process that, skip to the next element.
1252
dataReader
.Read(); // We're done here. To the next element.
1271
if (((object)
dataReader
.LocalName == XSD_SCHEMA && (object)
dataReader
.NamespaceURI == XSDNS )) {
1274
dataReader
.Skip(); // Yes, skip it
1278
dataTable.ReadXSDSchema(
dataReader
, false); // Invoke ReadXSDSchema on a table
1279
nodeToSchemaMap = new XmlToDatasetMap(
dataReader
.NameTable, dataTable);
1282
dataSet.ReadXSDSchema(
dataReader
, false); // Invoke ReadXSDSchema on a DataSet
1283
nodeToSchemaMap = new XmlToDatasetMap(
dataReader
.NameTable, dataSet);
1287
else if (((object)
dataReader
.LocalName == XDR_SCHEMA && (object)
dataReader
.NamespaceURI == XDRNS ) ||
1288
((object)
dataReader
.LocalName == SQL_SYNC && (object)
dataReader
.NamespaceURI == UPDGNS))
1290
dataReader
.Skip(); // Skip XDR or SQL sync