public void Shutdown()
{
lock (LocalLock) {
initialized = false;
AppDomain.CurrentDomain.AssemblyLoad -= new AssemblyLoadEventHandler (OnAssemblyLoaded);
AppDomain.CurrentDomain.AssemblyResolve -= CurrentDomainAssemblyResolve;
loadedAddins = new Dictionary<string, RuntimeAddin>();
loadedAssemblies = new Dictionary<Assembly, RuntimeAddin> ();
registry.Dispose ();
registry = null;
startupDirectory = null;
ClearContext ();
}
}