3 writes to attributes
System.Private.DataContractSerialization (3)
System\Runtime\Serialization\Json\XmlObjectSerializerReadContextComplexJson.cs (1)
147
attributes
??= new Attributes();
System\Runtime\Serialization\XmlObjectSerializerReadContext.cs (2)
82
this.
attributes
= new Attributes();
314
attributes
??= new Attributes();
60 references to attributes
System.Private.DataContractSerialization (60)
System\Runtime\Serialization\Json\XmlObjectSerializerReadContextComplexJson.cs (4)
148
attributes
.Reset();
152
attributes
.XsiNil = true;
157
attributes
.XsiTypeName = qualifiedTypeName.Name;
187
attributes
.XsiTypeNamespace = serverTypeNamespace;
System\Runtime\Serialization\XmlObjectSerializerReadContext.cs (54)
115
if (
attributes
.Ref != Globals.NewObjectId)
123
retObj = GetExistingObject(
attributes
.Ref, declaredType, name, ns);
128
else if (
attributes
.XsiNil)
151
Debug.Assert(
attributes
!= null);
153
if (
attributes
.XsiTypeName != null)
155
DataContract? tempDataContract = ResolveDataContractFromKnownTypes(
attributes
.XsiTypeName,
attributes
.XsiTypeNamespace, dataContract, declaredType);
160
throw XmlObjectSerializer.CreateSerializationException(XmlObjectSerializer.TryAddLineInfo(reader, SR.Format(SR.DcTypeNotFoundOnDeserialize,
attributes
.XsiTypeNamespace,
attributes
.XsiTypeName, reader.NamespaceURI, reader.LocalName)));
162
throw XmlObjectSerializer.CreateSerializationException(XmlObjectSerializer.TryAddLineInfo(reader, SR.Format(SR.DcTypeNotResolvedOnDeserialize,
attributes
.XsiTypeNamespace,
attributes
.XsiTypeName, reader.NamespaceURI, reader.LocalName)));
168
if (dataContract.IsISerializable &&
attributes
.FactoryTypeName != null)
170
DataContract? factoryDataContract = ResolveDataContractFromKnownTypes(
attributes
.FactoryTypeName,
attributes
.FactoryTypeNamespace, dataContract, declaredType);
294
Debug.Assert(
attributes
!= null);
296
if (
attributes
.Ref != Globals.NewObjectId)
300
return
attributes
.Ref;
302
else if (
attributes
.XsiNil)
311
[MemberNotNull(nameof(
attributes
))]
315
attributes
.Read(xmlReader);
320
attributes
?.Reset();
325
Debug.Assert(
attributes
!= null);
327
return
attributes
.Id;
337
Debug.Assert(
attributes
!= null);
339
AddNewObjectWithId(
attributes
.Id, obj);
565
if (
attributes
.Ref != Globals.NewObjectId)
568
value = GetExistingObject(
attributes
.Ref, null, name, string.Empty);
570
else if (
attributes
.XsiNil)
590
Debug.Assert(
attributes
!= null);
592
return (
attributes
.XsiTypeName == null) ? null : ResolveDataContractFromKnownTypes(
attributes
.XsiTypeName,
attributes
.XsiTypeNamespace, null /*memberTypeContract*/, null);
615
if (
attributes
.Ref != Globals.NewObjectId)
618
object o = GetExistingObjectOrExtensionData(
attributes
.Ref);
620
dataNode.Id =
attributes
.Ref;
622
else if (
attributes
.XsiNil)
631
if (
attributes
.XsiTypeName != null)
633
dataContractName =
attributes
.XsiTypeName;
634
dataContractNamespace =
attributes
.XsiTypeNamespace;
642
else if (
attributes
.FactoryTypeName != null)
669
if (
attributes
.Id == Globals.NewObjectId)
711
Debug.Assert(
attributes
!= null);
715
if (
attributes
.UnrecognizedAttributesFound)
765
Debug.Assert(
attributes
!= null);
769
dataNode.ClrAssemblyName =
attributes
.ClrAssembly;
770
dataNode.ClrTypeName =
attributes
.ClrType;
772
dataNode.Id =
attributes
.Id;
807
Debug.Assert(
attributes
!= null);
812
int arraySize =
attributes
.ArraySZSize;
864
Debug.Assert(
attributes
!= null);
869
dataNode.FactoryTypeName =
attributes
.FactoryTypeName;
870
dataNode.FactoryTypeNamespace =
attributes
.FactoryTypeNamespace;
1097
Debug.Assert(
attributes
!= null);
1099
return (
attributes
.ArraySZSize != -1);
System\Runtime\Serialization\XmlObjectSerializerReadContextComplex.cs (2)
123
Debug.Assert(
attributes
!= null);
125
return _preserveObjectReferences ?
attributes
.ArraySZSize : -1;