Ejemplo n.º 1
0
 public async Task UpdateAsync(StateTypes.StateMessage message)
 {
     if (State == null)
     {
         throw new InvalidOperationException("Can not start synchronizing until the service is initialized.");
     }
     State = StateModule.updateUsingStandardClock(message, State);
     OnChange?.Invoke();
     if (StateModule.hasChanges(State))
     {
         await SyncCoreAsync(isIncremental : true, ignoreIfSynchronizing : false);
     }
 }
Ejemplo n.º 2
0
 private SynchronizationStatus HasChanges() =>
 StateModule.hasChanges(State)
     ? SynchronizationStatus.HasChanges
     : SynchronizationStatus.NoChanges;