Beispiel #1
0
 public void Stop()
 {
     lock (this)
     {
         if (this.communication != null)
         {
             this.communication.Stop();
             this.communication = null;
         }
     }
 }
Beispiel #2
0
 public void Start(IList <string> prefixes)
 {
     lock (this)
     {
         if (this.communication != null)
         {
             throw new InvalidOperationException("this");
         }
         this.communication          = new HttpCommunication();
         this.communication.Received = (sender, e) => this.OnReceived(e);
         this.communication.Start(prefixes);
     }
 }