NotifyingChangeApplier.ApplyFullEnumerationChanges 方法 (ConflictResolutionPolicy, CollisionConflictResolutionPolicy, FullEnumerationChangeBatch, IChangeDataRetriever, 泛型 IEnumerable, SyncKnowledge, ForgottenKnowledge, INotifyingChangeApplierTarget, IConflictLogAccess, SyncSessionContext, SyncCallbacks)

对作为恢复同步组成部分的变更批执行冲突检测、并发冲突处理、约束冲突处理、变更应用以及冲突日志管理。

命名空间: Microsoft.Synchronization
程序集: Microsoft.Synchronization(在 microsoft.synchronization.dll 中)

语法

声明
Public Sub ApplyFullEnumerationChanges ( _
    resolutionPolicy As ConflictResolutionPolicy, _
    collisionConflictResolutionPolicy As CollisionConflictResolutionPolicy, _
    sourceChanges As FullEnumerationChangeBatch, _
    changeDataRetriever As IChangeDataRetriever, _
    destinationVersions As IEnumerable(Of ItemChange), _
    destinationKnowledge As SyncKnowledge, _
    destinationForgottenKnowledge As ForgottenKnowledge, _
    changeApplierTarget As INotifyingChangeApplierTarget, _
    conflictLogAccess As IConflictLogAccess, _
    syncSessionState As SyncSessionContext, _
    syncCallback As SyncCallbacks _
)
用法
Dim instance As NotifyingChangeApplier
Dim resolutionPolicy As ConflictResolutionPolicy
Dim collisionConflictResolutionPolicy As CollisionConflictResolutionPolicy
Dim sourceChanges As FullEnumerationChangeBatch
Dim changeDataRetriever As IChangeDataRetriever
Dim destinationVersions As IEnumerable(Of ItemChange)
Dim destinationKnowledge As SyncKnowledge
Dim destinationForgottenKnowledge As ForgottenKnowledge
Dim changeApplierTarget As INotifyingChangeApplierTarget
Dim conflictLogAccess As IConflictLogAccess
Dim syncSessionState As SyncSessionContext
Dim syncCallback As SyncCallbacks

instance.ApplyFullEnumerationChanges(resolutionPolicy, collisionConflictResolutionPolicy, sourceChanges, changeDataRetriever, destinationVersions, destinationKnowledge, destinationForgottenKnowledge, changeApplierTarget, conflictLogAccess, syncSessionState, syncCallback)
public void ApplyFullEnumerationChanges (
    ConflictResolutionPolicy resolutionPolicy,
    CollisionConflictResolutionPolicy collisionConflictResolutionPolicy,
    FullEnumerationChangeBatch sourceChanges,
    IChangeDataRetriever changeDataRetriever,
    IEnumerable<ItemChange> destinationVersions,
    SyncKnowledge destinationKnowledge,
    ForgottenKnowledge destinationForgottenKnowledge,
    INotifyingChangeApplierTarget changeApplierTarget,
    IConflictLogAccess conflictLogAccess,
    SyncSessionContext syncSessionState,
    SyncCallbacks syncCallback
)
public:
void ApplyFullEnumerationChanges (
    ConflictResolutionPolicy resolutionPolicy, 
    CollisionConflictResolutionPolicy collisionConflictResolutionPolicy, 
    FullEnumerationChangeBatch^ sourceChanges, 
    IChangeDataRetriever^ changeDataRetriever, 
    IEnumerable<ItemChange^>^ destinationVersions, 
    SyncKnowledge^ destinationKnowledge, 
    ForgottenKnowledge^ destinationForgottenKnowledge, 
    INotifyingChangeApplierTarget^ changeApplierTarget, 
    IConflictLogAccess^ conflictLogAccess, 
    SyncSessionContext^ syncSessionState, 
    SyncCallbacks^ syncCallback
)
public void ApplyFullEnumerationChanges (
    ConflictResolutionPolicy resolutionPolicy, 
    CollisionConflictResolutionPolicy collisionConflictResolutionPolicy, 
    FullEnumerationChangeBatch sourceChanges, 
    IChangeDataRetriever changeDataRetriever, 
    IEnumerable<ItemChange> destinationVersions, 
    SyncKnowledge destinationKnowledge, 
    ForgottenKnowledge destinationForgottenKnowledge, 
    INotifyingChangeApplierTarget changeApplierTarget, 
    IConflictLogAccess conflictLogAccess, 
    SyncSessionContext syncSessionState, 
    SyncCallbacks syncCallback
)
public function ApplyFullEnumerationChanges (
    resolutionPolicy : ConflictResolutionPolicy, 
    collisionConflictResolutionPolicy : CollisionConflictResolutionPolicy, 
    sourceChanges : FullEnumerationChangeBatch, 
    changeDataRetriever : IChangeDataRetriever, 
    destinationVersions : IEnumerable<ItemChange>, 
    destinationKnowledge : SyncKnowledge, 
    destinationForgottenKnowledge : ForgottenKnowledge, 
    changeApplierTarget : INotifyingChangeApplierTarget, 
    conflictLogAccess : IConflictLogAccess, 
    syncSessionState : SyncSessionContext, 
    syncCallback : SyncCallbacks
)

参数

  • resolutionPolicy
    用于解决冲突的策略。
  • collisionConflictResolutionPolicy
    用于解决抵触约束冲突的策略。
  • sourceChanges
    来自源提供程序的变更批。
  • changeDataRetriever
    可用于从源副本中检索项数据的对象。
  • destinationVersions
    一个包含存储在目标副本中的项的版本的变更批。这些项与 sourceChanges 中的项相对应。
  • destinationKnowledge
    目标副本的知识。
  • destinationForgottenKnowledge
    目标副本的遗忘知识。
  • changeApplierTarget
    将被调用以用于保存变更和冲突的对象。
  • conflictLogAccess
    在其中存储延迟冲突和临时冲突的冲突日志。
  • syncSessionState
    有关当前会话的状态信息。
  • syncCallback
    将接收有关变更应用事件的通知的回调。

备注

此方法检测 sourceChanges 中发送的变更与目标副本中相应项之间发生的并发冲突。它根据 resolutionPolicy 指定的策略来解决所有并发冲突。当目标提供程序报告抵触约束冲突时,此方法将根据 collisionConflictResolutionPolicy 指定的策略解决这些冲突。如果未设置冲突解决策略,则此方法会将冲突通知应用程序,然后应用程序指定一个冲突解决操作。如有必要,此方法随后会对 changeApplierTarget 调用方法,以将变更保存到目标副本中并保存未解决的冲突。

通过解决日志中的冲突并从日志中删除过时的冲突,变更应用方可帮助管理 conflictLogAccess 指定的冲突日志。变更应用方还可以使用冲突日志来存储因合并约束冲突而导致的临时冲突。在同步会话结束前,添加到日志中的任何临时冲突都将被删除。

请参阅

参考

NotifyingChangeApplier 类
NotifyingChangeApplier 成员
Microsoft.Synchronization 命名空间