DataContractResolver.TryResolveType Method
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
Override this method to map a data contract type to an xsi:type name and namespace during serialization.
Assembly: System.Runtime.Serialization (in System.Runtime.Serialization.dll)
public abstract bool TryResolveType( Type type, Type declaredType, DataContractResolver knownTypeResolver, out XmlDictionaryString typeName, out XmlDictionaryString typeNamespace )
Parameters
- type
- Type: System.Type
The type to map.
- declaredType
- Type: System.Type
The type declared in the data contract.
- knownTypeResolver
- Type: System.Runtime.Serialization.DataContractResolver
The known type resolver.
- typeName
- Type:
System.Xml.XmlDictionaryString
%
The xsi:type name.
- typeNamespace
- Type:
System.Xml.XmlDictionaryString
%
The xsi:type namespace.
Show: