100 references to UnderlyingType
dotnet-svcutil-lib (100)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\ClassDataContract.cs (18)
532throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.UnexpectedContractType, DataContract.GetClrTypeFullName(this.GetType()), DataContract.GetClrTypeFullName(UnderlyingType)))); 541throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.UnexpectedContractType, DataContract.GetClrTypeFullName(this.GetType()), DataContract.GetClrTypeFullName(UnderlyingType)))); 557if (!IsTypeVisible(UnderlyingType)) 564DataContract.GetClrTypeFullName(UnderlyingType)), 574if (Globals.TypeOfScriptObject_IsAssignableFrom(UnderlyingType)) 583DataContract.GetClrTypeFullName(UnderlyingType)), 596DataContract.GetClrTypeFullName(UnderlyingType), 610DataContract.GetClrTypeFullName(UnderlyingType), 630DataContract.GetClrTypeFullName(UnderlyingType), 639DataContract.GetClrTypeFullName(UnderlyingType), 661if (!IsTypeVisible(UnderlyingType)) 668DataContract.GetClrTypeFullName(UnderlyingType)), 684DataContract.GetClrTypeFullName(this.UnderlyingType), 698DataContract.GetClrTypeFullName(UnderlyingType), 718DataContract.GetClrTypeFullName(UnderlyingType), 727DataContract.GetClrTypeFullName(UnderlyingType), 891DataContract.GetClrTypeFullName(this.BaseContract.UnderlyingType), 1513Type type = UnderlyingType;
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\CodeExporter.cs (2)
286throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.UnexpectedContractType, DataContract.GetClrTypeFullName(dataContract.GetType()), DataContract.GetClrTypeFullName(dataContract.UnderlyingType)))); 351return GetCodeTypeReference(dataContract.UnderlyingType);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\CollectionDataContract.cs (9)
546if (UnderlyingType.GetTypeInfo().IsInterface && (Kind == CollectionKind.Enumerable || Kind == CollectionKind.Collection || Kind == CollectionKind.GenericEnumerable)) 548throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.GetOnlyCollectionMustHaveAddMethod, GetClrTypeFullName(UnderlyingType)))); 1314throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.CollectionTypeDoesNotHaveDefaultCtor, DataContract.GetClrTypeFullName(this.UnderlyingType)))); 1334if (!IsTypeVisible(UnderlyingType)) 1341DataContract.GetClrTypeFullName(UnderlyingType)), 1365DataContract.GetClrTypeFullName(UnderlyingType)), 1377DataContract.GetClrTypeFullName(UnderlyingType), 1394if (!IsTypeVisible(UnderlyingType)) 1401DataContract.GetClrTypeFullName(UnderlyingType)),
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataContract.cs (7)
148throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new SerializationException(string.Format(SRSerialization.ErrorDeserializing, string.Format(SRSerialization.ErrorTypeInfo, DataContract.GetClrTypeFullName(dataContract.UnderlyingType)), string.Format(SRSerialization.NoSetMethodForProperty, string.Empty, string.Empty)))); 309throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.UnexpectedContractType, DataContract.GetClrTypeFullName(this.GetType()), DataContract.GetClrTypeFullName(UnderlyingType)))); 314throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidDataContractException(string.Format(SRSerialization.UnexpectedContractType, DataContract.GetClrTypeFullName(this.GetType()), DataContract.GetClrTypeFullName(UnderlyingType)))); 635return (cachedContract != null && cachedContract.UnderlyingType == contract.UnderlyingType); 2180if (alreadyExistingContract.UnderlyingType != DataContractCriticalHelper.GetDataContractAdapterType(type) && 2182throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidOperationException(string.Format(SRSerialization.DupContractInKnownTypes, type, alreadyExistingContract.UnderlyingType, dataContract.StableName.Namespace, dataContract.StableName.Name)));
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataContractSerializer.cs (3)
311Type declaredType = contract.UnderlyingType; 349throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(XmlObjectSerializer.CreateSerializationException(string.Format(SRSerialization.IsAnyCannotBeSerializedAsDerivedType, graphType, contract.UnderlyingType))); 431if (contract.IsPrimitive && object.ReferenceEquals(contract.UnderlyingType, _rootType) /*handle Nullable<T> differently*/)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\DataContractSet.cs (10)
100EnsureTypeNotGeneric(dataContract.UnderlyingType); 129if (dataContract.UnderlyingType == null || dataContractInSet.UnderlyingType == null) 133bool typeNamesEqual = (DataContract.GetClrTypeFullName(dataContract.UnderlyingType) == DataContract.GetClrTypeFullName(dataContractInSet.UnderlyingType)); 134throw /*System.Runtime.Serialization.*/DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidOperationException(string.Format(SRSerialization.DupTypeContractInDataContractSet, (typeNamesEqual ? dataContract.UnderlyingType.AssemblyQualifiedName : DataContract.GetClrTypeFullName(dataContract.UnderlyingType)), (typeNamesEqual ? dataContractInSet.UnderlyingType.AssemblyQualifiedName : DataContract.GetClrTypeFullName(dataContractInSet.UnderlyingType)), dataContract.StableName.Name, dataContract.StableName.Namespace))); 176memberDataContract.UnderlyingType);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\EnumDataContract.cs (6)
371throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(XmlObjectSerializer.CreateSerializationException(string.Format(SRSerialization.InvalidEnumValueOnWrite, value, DataContract.GetClrTypeFullName(UnderlyingType)))); 377throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(XmlObjectSerializer.CreateSerializationException(string.Format(SRSerialization.InvalidEnumValueOnWrite, value, DataContract.GetClrTypeFullName(UnderlyingType)))); 417throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(XmlObjectSerializer.CreateSerializationException(string.Format(SRSerialization.InvalidEnumValueOnRead, stringValue, DataContract.GetClrTypeFullName(UnderlyingType)))); 422return Enum.ToObject(UnderlyingType, (object)(ulong)longValue); 423return Enum.ToObject(UnderlyingType, (object)longValue); 436throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(XmlObjectSerializer.CreateSerializationException(string.Format(SRSerialization.InvalidEnumValueOnRead, value.Substring(index, count), DataContract.GetClrTypeFullName(UnderlyingType))));
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\ExceptionDataContract.cs (2)
520ClassDataContract cdc = new ClassDataContract(this.UnderlyingType); 545if (primitiveContract == null || primitiveContract.UnderlyingType == Globals.TypeOfObject)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\PrimitiveDataContract.cs (6)
99if (UnderlyingType.GetTypeInfo().IsValueType) 100_helper.XmlFormatWriterMethod = typeof(XmlWriterDelegator).GetMethod(WriteMethodName, Globals.ScanAllMembers, new Type[] { UnderlyingType, typeof(XmlDictionaryString), typeof(XmlDictionaryString) }); 102_helper.XmlFormatWriterMethod = typeof(XmlObjectSerializerWriteContext).GetMethod(WriteMethodName, Globals.ScanAllMembers, new Type[] { typeof(XmlWriterDelegator), UnderlyingType, typeof(XmlDictionaryString), typeof(XmlDictionaryString) }); 119if (UnderlyingType.GetTypeInfo().IsValueType) 120_helper.XmlFormatContentWriterMethod = typeof(XmlWriterDelegator).GetMethod(WriteMethodName, Globals.ScanAllMembers, new Type[] { UnderlyingType }); 122_helper.XmlFormatContentWriterMethod = typeof(XmlObjectSerializerWriteContext).GetMethod(WriteMethodName, Globals.ScanAllMembers, new Type[] { typeof(XmlWriterDelegator), UnderlyingType });
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\SchemaImporter.cs (1)
208return dataContract is PrimitiveDataContract && ((PrimitiveDataContract)dataContract).UnderlyingType == Globals.TypeOfObject;
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlDataContract.cs (8)
207return UnderlyingType == Globals.TypeOfXmlElement || UnderlyingType == Globals.TypeOfXmlNodeArray; 357Type type = UnderlyingType; 390Type type = this.UnderlyingType; 444ilg.ConvertValue(this.UnderlyingType, Globals.TypeOfIXmlSerializable); 456if (!IsTypeVisible(UnderlyingType)) 461new SecurityException(string.Format(SRSerialization.PartialTrustIXmlSerializableTypeNotPublic, DataContract.GetClrTypeFullName(UnderlyingType)), 472new SecurityException(string.Format(SRSerialization.PartialTrustIXmlSerialzableNoPublicConstructor, DataContract.GetClrTypeFullName(UnderlyingType)),
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlFormatReaderGenerator.cs (7)
125if (classContract.UnderlyingType == Globals.TypeOfDateTimeOffsetAdapter) 203Type type = _objectType = classContract.UnderlyingType; 209if (classContract.UnderlyingType == Globals.TypeOfDBNull) 391if ((primitiveContract != null && primitiveContract.UnderlyingType != Globals.TypeOfObject) || nullables != 0 || type.GetTypeInfo().IsValueType) 430if (primitiveContract != null && primitiveContract.UnderlyingType != Globals.TypeOfObject) 500Type type = collectionContract.UnderlyingType; 639Type type = collectionContract.UnderlyingType;
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlFormatWriterGenerator.cs (6)
99InitArgs(classContract.UnderlyingType); 123InitArgs(collectionContract.UnderlyingType); 274_ilg.Call(null, XmlFormatGeneratorStatics.ThrowRequiredMemberMustBeEmittedMethod, member.Name, classContract.UnderlyingType); 321if (!TryWritePrimitiveArray(collectionContract.UnderlyingType, itemType, _objectLocal, itemName, itemNamespace)) 463if (primitiveContract == null || primitiveContract.UnderlyingType == Globals.TypeOfObject) 581if (primitiveContract != null && primitiveContract.UnderlyingType != Globals.TypeOfObject && !writeXsiType)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerContext.cs (4)
237return knownContract != null && knownContract.UnderlyingType == dataContract.UnderlyingType; 243return dataContract == null ? null : dataContract.UnderlyingType; 282&& !memberTypeContract.UnderlyingType.GetTypeInfo().IsInterface
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerReadContext.cs (3)
154if (TryHandleNullOrRef(reader, dataContract.UnderlyingType, name, ns, ref retObj)) 539if (xmlDataContract.UnderlyingType == Globals.TypeOfXmlElement) 546else if (xmlDataContract.UnderlyingType == Globals.TypeOfXmlNodeArray)
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerReadContextComplex.cs (2)
124if (this.IsGetOnlyCollection && dataContract.UnderlyingType != declaredType) 131object obj = DataContractSurrogateCaller.GetDeserializedObject(_serializationSurrogateProvider, oldObj, dataContract.UnderlyingType, declaredType);
FrameworkFork\System.Runtime.Serialization\System\Runtime\Serialization\XmlObjectSerializerWriteContext.cs (6)
161Type declaredType = rootTypeDataContract.UnderlyingType; 271if (knownContract == null || knownContract.UnderlyingType != dataContract.UnderlyingType) 273throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(XmlObjectSerializer.CreateSerializationException(string.Format(SRSerialization.DcTypeNotFoundOnSerialize, DataContract.GetClrTypeFullName(dataContract.UnderlyingType), dataContract.StableName.Name, dataContract.StableName.Namespace))); 631WriteResolvedTypeInfo(writer, contract.UnderlyingType, declaredContract.UnderlyingType);