Dispose() публичный Метод

Disposes of resources used by this instance.
public Dispose ( ) : void
Результат void
Пример #1
0
        /// <summary>
        /// Raises the bootstraps' ApplicationFilesChanged event.
        /// </summary>
        /// <param name="sender">The event sender.</param>
        /// <param name="e">The event arguments.</param>
        private static void BootstrapsApplicationFilesChanged(object sender, FileSystemEventArgs e)
        {
            logger.Info("A change was detected in '{0}'. Shutting down.", e.FullPath);

            lock (Locker)
            {
                if (bootstraps != null)
                {
                    bootstraps.Pushdown(false);
                    bootstraps.Dispose();
                    bootstraps = null;
                }
            }

            logger.Info("Re-starting the application at '{0}'.", options.ApplicationPath);
            PullupBootstraps();
        }