예제 #1
0
        //=====================================================================

        /// <inheritdoc />
        protected override void Dispose(bool disposing)
        {
            if (sandcastleProject != null)
            {
                sandcastleProject.Dispose();
                sandcastleProject = null;
            }

            try
            {
                if (webServerInstance != null && !webServerInstance.HasExited)
                {
                    webServerInstance.Kill();
                    webServerInstance.Dispose();
                }
            }
            catch (Exception ex)
            {
                // Ignore errors trying to kill the web server
                System.Diagnostics.Debug.WriteLine(ex.ToString());
            }
            finally
            {
                webServerInstance = null;
            }

            base.Dispose(disposing);
        }
예제 #2
0
        //=====================================================================

        /// <inheritdoc />
        protected override void Dispose(bool disposing)
        {
            if(sandcastleProject != null)
            {
                sandcastleProject.Dispose();
                sandcastleProject = null;
            }

            try
            {
                if(webServerInstance != null && !webServerInstance.HasExited)
                {
                    webServerInstance.Kill();
                    webServerInstance.Dispose();
                }
            }
            catch(Exception ex)
            {
                // Ignore errors trying to kill the web server
                System.Diagnostics.Debug.WriteLine(ex.ToString());
            }
            finally
            {
                webServerInstance = null;
            }

            base.Dispose(disposing);
        }