Dispose() приватный Метод

private Dispose ( ) : void
Результат void
Пример #1
0
 private static void UnloadPlugin(CorePlugin plugin)
 {
     disposedPlugins.Add(plugin.PluginAssembly);
     OnDiscardPluginData(new[] { plugin });
     plugins.Remove(plugin.AssemblyName);
     try
     {
         plugin.Dispose();
     }
     catch (Exception e)
     {
         Log.Core.WriteError("Error disposing plugin {1}: {0}", Log.Exception(e), plugin.AssemblyName);
     }
 }
Пример #2
0
		private static void UnloadPlugin(CorePlugin plugin)
		{
			disposedPlugins.Add(plugin.PluginAssembly);
			OnDiscardPluginData();
			plugins.Remove(plugin.AssemblyName);
			try
			{
				plugin.Dispose();
			}
			catch (Exception e)
			{
				Log.Core.WriteError("Error disposing plugin {1}: {0}", Log.Exception(e), plugin.AssemblyName);
			}
			CleanupAfterPlugins(new[] { plugin });
		}
Пример #3
0
		private static void RemovePlugin(CorePlugin plugin)
		{
			// Dispose plugin and discard plugin related data
			disposedPlugins.Add(plugin.PluginAssembly);
			OnDiscardPluginData();
			plugins.Remove(plugin.AssemblyName);
			try
			{
				plugin.Dispose();
			}
			catch (Exception e)
			{
				Log.Core.WriteError("Error disposing plugin {1}: {0}", Log.Exception(e), plugin.AssemblyName);
			}

			// Discard temporary plugin-related data (cached Types, etc.)
			CleanupAfterPlugins(new[] { plugin });
		}
Пример #4
0
		private static void UnloadPlugin(CorePlugin plugin)
		{
			OnDiscardPluginData(new[] { plugin });
			plugins.Remove(plugin.AssemblyName);
			disposedPlugins.Add(plugin.PluginAssembly);
			plugin.Dispose();
		}