SparkleLib.SparkleRepoBase.SyncUpBase C# (CSharp) Méthode

SyncUpBase() private méthode

private SyncUpBase ( ) : void
Résultat void
        private void SyncUpBase ()
        {
            if (!UseCustomWatcher)
                this.watcher.Disable ();

            SparkleLogger.LogInfo ("SyncUp", Name + " | Initiated");
            HasUnsyncedChanges = true;

            SyncStatusChanged (SyncStatus.SyncUp);

            if (SyncUp ()) {
                SparkleLogger.LogInfo ("SyncUp", Name + " | Done");
                ChangeSets = GetChangeSets ();

                HasUnsyncedChanges = false;
                this.poll_interval = PollInterval.Long;

                SyncStatusChanged (SyncStatus.Idle);
                this.listener.Announce (new SparkleAnnouncement (Identifier, CurrentRevision));

            } else {
                SparkleLogger.LogInfo ("SyncUp", Name + " | Error");
                SyncDownBase ();

                if (!UseCustomWatcher)
                    this.watcher.Disable ();

                if (Error == ErrorStatus.None && SyncUp ()) {
                    HasUnsyncedChanges = false;

                    this.listener.Announce (new SparkleAnnouncement (Identifier, CurrentRevision));
                    SyncStatusChanged (SyncStatus.Idle);

                } else {
                    this.poll_interval = PollInterval.Short;
                    SyncStatusChanged (SyncStatus.Error);
                }
            }

            ProgressPercentage = 0.0;
            ProgressSpeed      = 0.0;

            if (!UseCustomWatcher)
                this.watcher.Enable ();
        }