如何使用 SyncOrchestrator 按 Table 指定 SyncDirectionOrder

How to specify SyncDirectionOrder by Table using SyncOrchestrator

我已经将表分成不同的范围,具有不同的 SyncDirectionOrder 因为我还没有弄清楚如何使用单个范围来做到这一点:

public void Sync()
{
    Sync("BidirectionalScope", SyncDirectionOrder.DownloadAndUpload);
    Sync("UploadScope", SyncDirectionOrder.Upload);
    Sync("DownloadScope", SyncDirectionOrder.Download);
} 

protected SyncOperationStatistics Sync(string syncScope, SyncDirectionOrder syncDirectionOrder)
{
    var localProvider = new SqlSyncProvider(...);
    var remoteProvider = new SqlSyncProvider(...);

    var syncOrchestrator = new SyncOrchestrator
    {
        LocalProvider = localProvider,
        RemoteProvider = remoteProvider,
        Direction = syncDirectionOrder
    };

    return syncOrchestrator.Synchronize();
}

你不能,使用 Syncorchestrator,作用域是唯一可以指定同步方向的地方。