ProxyDataContractResolver.TryResolveType Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
During serialization, maps actual types to xsi:type
information.
public:
override bool TryResolveType(Type ^ dataContractType, Type ^ declaredType, System::Runtime::Serialization::DataContractResolver ^ knownTypeResolver, [Runtime::InteropServices::Out] System::Xml::XmlDictionaryString ^ % typeName, [Runtime::InteropServices::Out] System::Xml::XmlDictionaryString ^ % typeNamespace);
public override bool TryResolveType (Type dataContractType, Type declaredType, System.Runtime.Serialization.DataContractResolver knownTypeResolver, out System.Xml.XmlDictionaryString typeName, out System.Xml.XmlDictionaryString typeNamespace);
override this.TryResolveType : Type * Type * System.Runtime.Serialization.DataContractResolver * XmlDictionaryString * XmlDictionaryString -> bool
Public Overrides Function TryResolveType (dataContractType As Type, declaredType As Type, knownTypeResolver As DataContractResolver, ByRef typeName As XmlDictionaryString, ByRef typeNamespace As XmlDictionaryString) As Boolean
Parameters
- dataContractType
- Type
The actual type of the persistence-ignorant object.
- declaredType
- Type
The declared type.
- knownTypeResolver
- DataContractResolver
An instance of ProxyDataContractResolver.
- typeName
- XmlDictionaryString
When this method returns, contains a list of xsi:type
declarations.
- typeNamespace
- XmlDictionaryString
When this method returns, contains a list of namespaces used.
Returns
true
if the type was resolved; otherwise, false
.
Remarks
For more information, see: Working with POCO Entities.
Applies to
Feedback
https://aka.ms/ContentUserFeedback.
Kommer snart: I hele 2024 udfaser vi GitHub-problemer som feedbackmekanisme for indhold og erstatter det med et nyt feedbacksystem. Du kan få flere oplysninger under:Indsend og få vist feedback om