Exemplo n.º 1
0
 public void UpdateAllSinks(SkimChecker skimChecker)
 {
     lock (_managers)
     {
         foreach (var manager in _managers)
         {
             manager.UpdateSink(skimChecker);
         }
     }
 }
Exemplo n.º 2
0
        public void RemoveSkimChecker(SkimChecker skimChecker)
        {
            // This call will always happen on the UI thread (it is a side-effect of adding or removing the 1st/last tagger).
            lock (_managers)
            {
                _skimCheckers.Remove(skimChecker);

                foreach (var manager in _managers)
                {
                    manager.RemoveSkimChecker(skimChecker);
                }
            }
        }
Exemplo n.º 3
0
        public void AddSkimChecker(SkimChecker skimChecker)
        {
            // This call will always happen on the UI thread (it is a side-effect of adding or removing the 1st/last tagger).
            lock (_managers)
            {
                _skimCheckers.Add(skimChecker);

                // Tell the preexisting managers about the new skim checker
                foreach (var manager in _managers)
                {
                    manager.AddSkimChecker(skimChecker);
                }
            }
        }
Exemplo n.º 4
0
        private void UpdateSecurityErrors(DevSkimErrorsSnapshot securityErrors)
        {
            // Tell our factory to snap to a new snapshot.
            this.Factory.UpdateErrors(securityErrors);

            LastSecurityErrors = securityErrors;

            // Tell the provider to mark all the sinks dirty (so, as a side-effect, they will start an update pass that will get the new snapshot
            // from the factory).
            SkimChecker skimChecker = new SkimChecker(this._provider, this._textView, this._buffer);

            skimChecker._isDisposed = true;
            _provider.UpdateAllSinks(skimChecker);

            foreach (var tagger in _activeTaggers)
            {
                tagger.UpdateErrors(_currentSnapshot, securityErrors);
            }
        }
Exemplo n.º 5
0
 internal DevSkimTagger(SkimChecker skimhecker)
 {
     _skimChecker    = skimhecker;
     _securityErrors = skimhecker.LastSecurityErrors;
     skimhecker.AddTagger(this);
 }
Exemplo n.º 6
0
        public DevSkimErrorsFactory(SkimChecker skimChecker, DevSkimErrorsSnapshot securityErrors)
        {
            _skimChecker = skimChecker;

            this.CurrentSnapshot = securityErrors;
        }
Exemplo n.º 7
0
 internal void UpdateSink(SkimChecker skimChecker)
 {
     _sink.FactorySnapshotChanged(skimChecker.Factory);
 }
Exemplo n.º 8
0
 internal void RemoveSkimChecker(SkimChecker skimChecker)
 {
     _sink.RemoveFactory(skimChecker.Factory);
 }
Exemplo n.º 9
0
 internal void AddSkimChecker(SkimChecker skimChecker)
 {
     _sink.AddFactory(skimChecker.Factory);
 }