コード例 #1
0
ファイル: ImageServer.cs プロジェクト: karasnov/ImageService
 /// <summary>
 /// CloseSpecipicHandler function.
 /// closes specipic handler.
 /// </summary>
 /// <param name="toBeDeletedHandler">path of to be deleted handler</param>
 internal void CloseSpecipicHandler(string toBeDeletedHandler)
 {
     if (Handlers.ContainsKey(toBeDeletedHandler))
     {
         IDirectoryHandler handler = Handlers[toBeDeletedHandler];
         this.CloseServer -= handler.StopHandler;
         handler.StopHandler(this, null);
     }
 }
コード例 #2
0
 /// <summary>
 /// Closing wanted handler.
 /// </summary>
 /// <param name="handler"></param>
 internal void CloseHandler(string path)
 {
     //making sure path the wanted path exists
     if (HandlerPerPath.ContainsKey(path))
     {
         IDirectoryHandler handler = HandlerPerPath[path];
         this.CloseServer -= handler.StopHandler;
         handler.StopHandler(this, null);
     }
 }