Share via


SaveChangeContext.DestinationVersionSuppliedForChange Property

Gets an ItemChange object that contains the original version that the destination provider supplied to the change applier.

Namespace: Microsoft.Synchronization
Assembly: Microsoft.Synchronization (in microsoft.synchronization.dll)

Syntax

'Declaration
Public ReadOnly Property DestinationVersionSuppliedForChange As ItemChange
'Usage
Dim instance As SaveChangeContext
Dim value As ItemChange

value = instance.DestinationVersionSuppliedForChange
public ItemChange DestinationVersionSuppliedForChange { get; }
public:
property ItemChange^ DestinationVersionSuppliedForChange {
    ItemChange^ get ();
}
/** @property */
public ItemChange get_DestinationVersionSuppliedForChange ()
public function get DestinationVersionSuppliedForChange () : ItemChange

Property Value

An ItemChange object that contains the original version that the destination provider supplied to the change applier.

Remarks

This property can be used to implement an optimistic concurrency check. To do this, the destination provider compares the version that is contained in the returned ItemChange object to the current version in its metadata. If the versions are not the same, the item has been changed on the destination replica between the time that the change application was started and the time INotifyingChangeApplierTarget.SaveItemChange was called. If this occurs, the destination provider must report an error by using RecordRecoverableErrorForItem, and the metadata and item data for this change must not be applied. Be aware that this concurrency check is effective only if versions are updated in the metadata store before this concurrency check is performed, such as on a system on which versions are updated in the metadata store at the same time that item changes are made in the item store.

See Also

Reference

SaveChangeContext Class
SaveChangeContext Members
Microsoft.Synchronization Namespace