35 writes to Namespace
System.Xml (35)
System\Xml\Serialization\Mappings.cs (2)
150
newAccessor.
Namespace
= this.Namespace;
206
Namespace
= XmlReservedNs.NsXml;
System\Xml\Serialization\SoapReflectionImporter.cs (5)
112
element.
Namespace
= element.Mapping.Namespace == null ? defaultNamespace : element.Mapping.Namespace;
155
element.
Namespace
= element.Mapping.Namespace == null ? ns : element.Mapping.Namespace;
650
attribute.
Namespace
= a.SoapAttribute == null || a.SoapAttribute.Namespace == null ? ns : a.SoapAttribute.Namespace;
664
element.
Namespace
= ns;
677
element.
Namespace
= ns;
System\Xml\Serialization\SoapSchemaImporter.cs (7)
71
accessor.
Namespace
= name.Namespace;
96
accessor.
Namespace
= typeMapping.Namespace != null ? typeMapping.Namespace : ns;
152
accessor.
Namespace
= ns;
173
accessor.
Namespace
= ns;
390
arrayAccessor.
Namespace
= ns;
406
itemAccessor.
Namespace
= ns;
459
itemAccessor.
Namespace
= ns;
System\Xml\Serialization\XmlReflectionImporter.cs (12)
198
element.
Namespace
= ns;
1306
arrayItemElement.
Namespace
= xmlArrayItem.Namespace == null ? arrayElementNs : xmlArrayItem.Namespace;
1383
attribute.
Namespace
= a.XmlAttribute.Namespace == null ? ns : a.XmlAttribute.Namespace;
1426
element.
Namespace
= rpc ? null : xmlElement.Namespace == null ? ns : xmlElement.Namespace;
1473
element.
Namespace
= anyNs == null ? ns : anyNs;
1512
arrayElement.
Namespace
= rpc ? null : a.XmlArray.Namespace == null ? ns : a.XmlArray.Namespace;
1545
attribute.
Namespace
= a.XmlAttribute.Namespace == null ? ns : a.XmlAttribute.Namespace;
1583
element.
Namespace
= rpc ? null : xmlElement.Namespace == null ? ns : xmlElement.Namespace;
1638
element.
Namespace
= rpc ? null : xmlElement.Namespace == null ? ns : xmlElement.Namespace;
1688
element.
Namespace
= anyNs == null ? ns : anyNs;
1944
element.
Namespace
= ns;
1968
element.
Namespace
= ns;
System\Xml\Serialization\XmlSchemaImporter.cs (9)
138
accessor.
Namespace
= typeName.Namespace;
200
accessor.
Namespace
= typeName.Namespace;
267
accessor.
Namespace
= ns;
313
accessor.
Namespace
= ns;
846
choiceAccessor.
Namespace
= ns;
1148
accessor.
Namespace
= ns;
1172
arrayAccessor.
Namespace
= ns;
1480
accessor.
Namespace
= XmlReservedNs.NsXml;
1514
accessor.
Namespace
= ns;
139 references to Namespace
System.Xml (139)
System\Xml\Serialization\Mappings.cs (10)
114
return (
Namespace
== null ? "##any" :
Namespace
) + ":" + Name;
117
return
Namespace
== defaultNs ? Name :
Namespace
+ ":" + Name;
150
newAccessor.Namespace = this.
Namespace
;
210
if (
Namespace
== XmlReservedNs.NsXml) {
735
if (a[i].Name != b[i].Name || a[i].
Namespace
!= b[i].
Namespace
|| a[i].Form != b[i].Form || a[i].IsNullable != b[i].IsNullable)
753
return (Attribute.Name == mapping.Attribute.Name && Attribute.
Namespace
== mapping.Attribute.
Namespace
&& Attribute.Form == mapping.Attribute.Form);
System\Xml\Serialization\SoapSchemaExporter.cs (1)
263
element.SchemaTypeName = ExportTypeMapping(accessor.Mapping, accessor.
Namespace
);
System\Xml\Serialization\XmlCodeExporter.cs (17)
86
ExportType(mapping.Attribute.Mapping, Accessor.UnescapeName(mapping.Attribute.Name), mapping.Attribute.
Namespace
, null, false);
91
ExportType(element.Mapping, Accessor.UnescapeName(element.Name), element.
Namespace
, null, false);
95
ExportType(mapping.Text.Mapping, Accessor.UnescapeName(mapping.Text.Name), mapping.Text.
Namespace
, null, false);
102
ExportType(element.Mapping, Accessor.UnescapeName(element.Name), element.
Namespace
, element, true);
577
AddRootMetadata(metadata, mapping.Mapping, Accessor.UnescapeName(mapping.Accessor.Name), mapping.Accessor.
Namespace
, mapping.Accessor);
603
bool sameElementNs = arrayElement.Form == XmlSchemaForm.Unqualified || arrayElement.
Namespace
== ns;
607
ExportArrayItem(metadata, sameName ? null : elementName, sameElementNs ? null : arrayElement.
Namespace
, sameElementType ? null : elementMapping.TypeDesc, elementMapping.TypeDesc, arrayElement.IsNullable, defaultForm ? XmlSchemaForm.None : arrayElement.Form, nestingLevel);
628
bool sameNs = attribute.
Namespace
== ns;
632
sameNs || defaultForm ? null : attribute.
Namespace
,
653
bool sameNs = element.
Namespace
== ns;
657
ExportAnyElement(metadata, elemName, element.
Namespace
, member.SequenceId);
662
ExportArray(metadata, sameName ? null : elemName, sameNs ? null : element.
Namespace
, element.IsNullable, defaultForm ? XmlSchemaForm.None : element.Form, member.SequenceId);
668
ExportArrayElements(metadata, array, element.
Namespace
, member.TypeDesc.ArrayElementTypeDesc, 0);
675
ExportElement(metadata, sameName ? null : elemName, sameNs ? null : element.
Namespace
, sameType ? null : mapping.TypeDesc, mapping.TypeDesc, element.IsNullable, defaultForm ? XmlSchemaForm.None : element.Form, member.SequenceId);
683
bool sameNs = element.
Namespace
== ns;
685
ExportAnyElement(metadata, elemName, element.
Namespace
, member.SequenceId);
688
ExportElement(metadata, elemName, sameNs ? null : element.
Namespace
, ((TypeMapping)element.Mapping).TypeDesc, ((TypeMapping)element.Mapping).TypeDesc, element.IsNullable, defaultForm ? XmlSchemaForm.None : element.Form, member.SequenceId);
System\Xml\Serialization\XmlMapping.cs (1)
73
get { return accessor.
Namespace
; }
System\Xml\Serialization\XmlMemberMapping.cs (1)
58
get { return Accessor.
Namespace
; }
System\Xml\Serialization\XmlReflectionImporter.cs (40)
273
if (accessor.
Namespace
== ns) return accessor;
281
Accessor existing = (Accessor)accessors[accessor.Name, accessor.
Namespace
];
284
accessors.Add(accessor.Name, accessor.
Namespace
, accessor);
302
throw new InvalidOperationException(Res.GetString(Res.XmlCannotReconcileAccessorDefault, accessor.Name, accessor.
Namespace
, value1, value2));
307
throw new InvalidOperationException(Res.GetString(Res.XmlMethodTypeNameConflict, accessor.Name, accessor.
Namespace
));
311
throw new InvalidOperationException(Res.GetString(Res.XmlCannotReconcileAccessor, accessor.Name, accessor.
Namespace
, GetMappingName(existing.Mapping), GetMappingName(accessor.Mapping)));
327
throw new InvalidOperationException(Res.GetString(Res.XmlCannotReconcileAttributeAccessor, accessor.Name, accessor.
Namespace
, GetMappingName(existing.Mapping), GetMappingName(accessor.Mapping)));
329
throw new InvalidOperationException(Res.GetString(Res.XmlCannotReconcileAccessor, accessor.Name, accessor.
Namespace
, GetMappingName(existing.Mapping), GetMappingName(accessor.Mapping)));
927
ns = element.
Namespace
;
1307
arrayItemElement.Mapping = ImportTypeMapping(modelScope.GetTypeModel(targetType), arrayItemElement.
Namespace
, ImportContext.Element, xmlArrayItem.DataType, null, limiter);
1311
CheckForm(arrayItemElement.Form, arrayElementNs != arrayItemElement.
Namespace
);
1385
if (attribute.Form == XmlSchemaForm.None && ns != attribute.
Namespace
) {
1389
CheckForm(attribute.Form, ns != attribute.
Namespace
);
1394
if (attribute.Form == XmlSchemaForm.Qualified && attribute.
Namespace
!= ns) {
1427
element.Mapping = ImportTypeMapping(typeModel, rpc ? ns : element.
Namespace
, ImportContext.Element, xmlElement.DataType, null, limiter);
1444
CheckForm(element.Form, ns != element.
Namespace
);
1480
element.Mapping = ImportTypeMapping(typeModel, element.
Namespace
, ImportContext.Element, String.Empty, null, limiter);
1487
CheckForm(element.Form, ns != element.
Namespace
);
1490
elements.Add(element.Name, element.
Namespace
, element);
1514
savedArrayNamespace = arrayElement.
Namespace
;
1522
CheckForm(arrayElement.Form, ns != arrayElement.
Namespace
);
1547
if (attribute.Form == XmlSchemaForm.None && ns != attribute.
Namespace
) {
1551
CheckForm(attribute.Form, ns != attribute.
Namespace
);
1555
if (attribute.Form == XmlSchemaForm.Qualified && attribute.
Namespace
!= ns) {
1585
element.Mapping = ImportTypeMapping(typeModel, rpc ? ns : element.
Namespace
, ImportContext.Element, xmlElement.DataType, null, limiter);
1598
CheckForm(element.Form, ns != element.
Namespace
);
1639
element.Mapping = ImportTypeMapping(typeModel, rpc ? ns : element.
Namespace
, ImportContext.Element, xmlElement.DataType, null, false, openModel, limiter);
1655
CheckForm(element.Form, ns != element.
Namespace
);
1696
element.Mapping = ImportTypeMapping(typeModel, element.
Namespace
, ImportContext.Element, String.Empty, null, false, openModel, limiter);
1702
CheckForm(element.Form, ns != element.
Namespace
);
1710
elements.Add(element.Name, element.
Namespace
, element);
1751
if ((element.Form == XmlSchemaForm.Unqualified && string.IsNullOrEmpty(choiceNs)) || element.
Namespace
== choiceNs) {
1764
string id = element.
Namespace
!= null && element.
Namespace
.Length > 0 ? element.
Namespace
+ ":" + element.Name : element.Name;
1766
throw new InvalidOperationException(Res.GetString(Res.XmlChoiceMissingValue, accessor.ChoiceIdentifier.Mapping.TypeDesc.FullName, id, element.Name, element.
Namespace
));
1894
Accessor existing = (Accessor)scope[accessor.Name, accessor.
Namespace
];
1897
throw new InvalidOperationException(Res.GetString(Res.XmlDuplicateElementName, existing.Name, existing.
Namespace
));
1904
throw new InvalidOperationException(Res.GetString(Res.XmlDuplicateAttributeName, existing.Name, existing.
Namespace
));
1908
scope[accessor.Name, accessor.
Namespace
] = accessor;
System\Xml\Serialization\XmlSchemaExporter.cs (23)
60
XmlSchemaType type = ExportSpecialMapping(special, xmlMembersMapping.Accessor.
Namespace
, false, null);
63
AddSchemaItem(type, xmlMembersMapping.Accessor.
Namespace
, null);
66
return (new XmlQualifiedName(xmlMembersMapping.Accessor.Name, xmlMembersMapping.Accessor.
Namespace
));
106
ExportMapping(member.Elements[0].Mapping, member.Elements[0].
Namespace
, member.Elements[0].Any);
240
AddSchemaItem(element, accessor.
Namespace
, null);
241
ExportElementMapping(element, accessor.Mapping, accessor.
Namespace
, accessor.Any);
662
if (accessor.
Namespace
== null || accessor.
Namespace
== ns) {
677
AddSchemaItem(attribute, accessor.
Namespace
, ns);
682
refAttribute.RefName = new XmlQualifiedName(accessor.Name, accessor.
Namespace
);
684
AddSchemaImport(accessor.
Namespace
, ns);
696
list.ItemTypeName = ExportPrimitiveMapping(pm, accessor.
Namespace
== null ? ns : accessor.
Namespace
);
706
attribute.SchemaTypeName = ExportPrimitiveMapping(pm, accessor.
Namespace
== null ? ns : accessor.
Namespace
);
724
if (accessor.
Namespace
!= null && accessor.
Namespace
.Length > 0 && accessor.
Namespace
!= ns)
725
any.Namespace = accessor.
Namespace
;
743
AddSchemaItem(element, accessor.
Namespace
, ns);
756
ExportElementMapping(element, (TypeMapping)accessor.Mapping, accessor.
Namespace
, accessor.Any);
760
refElement.RefName = new XmlQualifiedName(accessor.Name, accessor.
Namespace
);
764
AddSchemaImport(accessor.
Namespace
, ns);
System\Xml\Serialization\XmlSchemaImporter.cs (4)
948
ElementAccessor scopeElement = (ElementAccessor)scope[element.Name, element.
Namespace
];
951
throw new InvalidOperationException(Res.GetString(Res.XmlDuplicateElementInScope, element.Name, element.
Namespace
));
954
throw new InvalidOperationException(Res.GetString(Res.XmlDuplicateElementInScope1, element.Name, element.
Namespace
));
959
scope[element.Name, element.
Namespace
] = element;
System\Xml\Serialization\XmlSerializationGeneratedCode.cs (1)
276
WriteQuotedCSharpString(mapping.Accessor.
Namespace
);
System\Xml\Serialization\XmlSerializationILGen.cs (1)
331
ilg.Ldstr(mapping.Accessor.
Namespace
);
System\Xml\Serialization\XmlSerializationReader.cs (7)
2233
string expectedElement = e.Form == XmlSchemaForm.Qualified ? e.
Namespace
: "";
2351
WriteIsStartTag(element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
2513
WriteXmlNodeEqual("Reader", element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
3465
WriteXmlNodeEqual("Reader", attribute.Name, attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: "");
3524
qnames += attribute.IsSpecialXmlNamespace ? XmlReservedNs.NsXml : (attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: "") + ":" + attribute.Name;
3714
string ns = e.Form == XmlSchemaForm.Qualified ? e.
Namespace
: "";
3906
string ns = e.Form == XmlSchemaForm.Qualified ? e.
Namespace
: "";
System\Xml\Serialization\XmlSerializationReaderILGen.cs (6)
321
string expectedElement = e.Form == XmlSchemaForm.Qualified ? e.
Namespace
: "";
442
WriteIsStartTag(element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
1895
WriteXmlNodeEqual("Reader", attribute.Name, attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: "");
2064
qnames += attribute.IsSpecialXmlNamespace ? XmlReservedNs.NsXml : (attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: "") + ":" + attribute.Name;
2264
string ns = e.Form == XmlSchemaForm.Qualified ? e.
Namespace
: "";
2525
string ns = e.Form == XmlSchemaForm.Qualified ? e.
Namespace
: "";
System\Xml\Serialization\XmlSerializationWriter.cs (14)
1628
WriteStartElement(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""), mapping.IsSoap);
1804
WriteEncodedNullTag(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""));
1806
WriteLiteralNullTag(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""));
1809
WriteEmptyTag(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""));
2226
string ns = attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: String.Empty;
2330
string ns = attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: String.Empty;
2369
WritePrimitive("WriteAttribute", attribute.Name, attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: "", attribute.Default, source, attribute.Mapping, false, false, false);
2633
WriteQuotedCSharpString(element.
Namespace
);
2748
string ns = element.Any && element.Name.Length == 0 ? null : (element.Form == XmlSchemaForm.Qualified ? (writeAccessor ? element.
Namespace
: element.Mapping.Namespace) : "");
2766
WriteLiteralNullTag(element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
3048
WriteLiteralNullTag(element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
3210
if ((element.Form == XmlSchemaForm.Unqualified && string.IsNullOrEmpty(choiceNs)) || element.
Namespace
== choiceNs) {
3225
throw new InvalidOperationException(Res.GetString(Res.XmlChoiceMissingValue, choiceMapping.TypeDesc.FullName, element.
Namespace
+ ":" + element.Name, element.Name, element.
Namespace
));
System\Xml\Serialization\XmlSerializationWriterILGen.cs (13)
365
WriteStartElement(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""), false);
525
WriteLiteralNullTag(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""));
528
WriteEmptyTag(element.Name, (element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: ""));
1125
string ns = attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: String.Empty;
1287
string ns = attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: String.Empty;
1347
WritePrimitive("WriteAttribute", attribute.Name, attribute.Form == XmlSchemaForm.Qualified ? attribute.
Namespace
: "", GetConvertedDefaultValue(source.Type, attribute.Default), source, attribute.Mapping, false, false, false);
1678
ilg.Ldstr(element.
Namespace
);
1847
string ns = element.Any && element.Name.Length == 0 ? null : (element.Form == XmlSchemaForm.Qualified ? (writeAccessor ? element.
Namespace
: element.Mapping.Namespace) : "");
1873
WriteLiteralNullTag(element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
2125
WriteLiteralNullTag(element.Name, element.Form == XmlSchemaForm.Qualified ? element.
Namespace
: "");
2191
if ((element.Form == XmlSchemaForm.Unqualified && string.IsNullOrEmpty(choiceNs)) || element.
Namespace
== choiceNs) {
2204
throw new InvalidOperationException(Res.GetString(Res.XmlChoiceMissingValue, choiceMapping.TypeDesc.FullName, element.
Namespace
+ ":" + element.Name, element.Name, element.
Namespace
));