Sdílet prostřednictvím


IReplicaMetadata::GetItemBatchVersions

Gets a batch of changes that contains the versions of items and change units that are stored in this replica. These items and change units correspond to the items and change units referred to in a batch of changes that is sent from some other provider.

HRESULT GetItemBatchVersions(
  ISyncChangeBatch * pRemoteSyncChangeBatch,
  IEnumSyncChanges ** ppLocalVersionsEnum);

Parameters

  • pRemoteSyncChangeBatch
    [in] The batch of changes sent from another provider that is about to be applied to the item store that is associated with this replica.
  • ppLocalVersionsEnum
    [out] Returns a batch of changes that contains the versions of items and change units that are stored in this replica.

Return Value

  • S_OK

  • E_POINTER

Remarks

This method helps a synchronization provider implement its IKnowledgeSyncProvider::ProcessChangeBatch method.

Change appliers use the versions in the batch of changes that are returned from this method for conflict detection.

Notes for Implementers

The change batch that is returned from this method must contain one entry for every entry in pRemoteSyncChangeBatch, including change unit entries. If an item exists in the item store, its entry must contain its version information for this replica. If an item does not exist, its version must be set to a replica key of 0 and a tick count of 0, and its SYNC_CHANGE_FLAG_DOES_NOT_EXIST flag must be set.

See Also

Reference

IReplicaMetadata Interface