SyncMetadataStoreSerializer.DeserializeReplicaMetadata Method
When overridden in a derived class, deserializes the contents of a metadata file to a metadata storage service store.
Namespace: Microsoft.Synchronization.MetadataStorage
Assembly: Microsoft.Synchronization.MetadataStorage (in Microsoft.Synchronization.MetadataStorage.dll)
Syntax
'Declaration
Public MustOverride Function DeserializeReplicaMetadata ( _
serializedFilePath As String, _
expectedProviderCompatibilityVersion As UInteger, _
providerUpgradeCallback As IProviderUpgradeCallback _
) As Boolean
'Usage
Dim instance As SyncMetadataStoreSerializer
Dim serializedFilePath As String
Dim expectedProviderCompatibilityVersion As UInteger
Dim providerUpgradeCallback As IProviderUpgradeCallback
Dim returnValue As Boolean
returnValue = instance.DeserializeReplicaMetadata(serializedFilePath, _
expectedProviderCompatibilityVersion, _
providerUpgradeCallback)
public abstract bool DeserializeReplicaMetadata(
string serializedFilePath,
uint expectedProviderCompatibilityVersion,
IProviderUpgradeCallback providerUpgradeCallback
)
public:
virtual bool DeserializeReplicaMetadata(
String^ serializedFilePath,
unsigned int expectedProviderCompatibilityVersion,
IProviderUpgradeCallback^ providerUpgradeCallback
) abstract
abstract DeserializeReplicaMetadata :
serializedFilePath:string *
expectedProviderCompatibilityVersion:uint32 *
providerUpgradeCallback:IProviderUpgradeCallback -> bool
public abstract function DeserializeReplicaMetadata(
serializedFilePath : String,
expectedProviderCompatibilityVersion : uint,
providerUpgradeCallback : IProviderUpgradeCallback
) : boolean
Parameters
- serializedFilePath
Type: System.String
The file that contains the serialized metadata for a particular replica.
- expectedProviderCompatibilityVersion
Type: System.UInt32
The provider compatibility version that is expected to be included in the canonical metadata file. If the expected version does not match the actual version, deserialization either fails by design when providerUpgradeCallback is a null reference (Nothing in Visual Basic), or providerUpgradeCallback methods are called when providerUpgradeCallback is not null reference (Nothing in Visual Basic). For more information, see fb008b8f-a90b-4cbc-b718-7cb9c92a26ea Accessing Metadata from Components with Different Versions and b3ff82fb-f946-4b7f-8a32-655535cf5e92 Upgrading the Metadata Store Version .
- providerUpgradeCallback
Type: Microsoft.Synchronization.MetadataStorage.IProviderUpgradeCallback
Callback methods that are called when the metadata store format must be upgraded because the provider version contained in the serialized metadata is not the same as expectedProviderCompatibilityVersion.
Return Value
Type: System.Boolean
true when there is metadata to deserialize; otherwise, false.