internal DnAssembly(DnAppDomain appDomain, ICorDebugAssembly assembly, int incrementedId) { this.appDomain = appDomain; this.modules = new DebuggerCollection<ICorDebugModule, DnModule>(CreateModule); this.assembly = new CorAssembly(assembly); this.incrementedId = incrementedId; }
// // IEnumerator interface // public bool MoveNext () { ICorDebugAssembly[] a = new ICorDebugAssembly[1]; uint c = 0; int r = m_enum.Next ((uint) a.Length, a, out c); if (r==0 && c==1) // S_OK && we got 1 new element m_asm = new CorAssembly (a[0]); else m_asm = null; return m_asm != null; }
public CorAssembly(ICorDebugAssembly assembly) { corAssembly = assembly; char[] name = new char[300]; uint sz = 0; corAssembly.GetName((uint)name.Length, out sz, name); fullName = new String(name, 0, (int)(sz - 1)); if (fullName.Contains(Path.DirectorySeparatorChar)) { assemblyname = Path.GetFileName(fullName); location = Path.GetDirectoryName(fullName); } else { assemblyname = location = fullName; } }
private IList<DebugAssembly> LoadAssemblies() { ICorDebugAssemblyEnum assembliesEnum; _domain.EnumerateAssemblies(out assembliesEnum); uint assembliesCount; assembliesEnum.GetCount(out assembliesCount); ICorDebugAssembly[] assemblies = new ICorDebugAssembly[assembliesCount]; uint actualAssembliesCount; assembliesEnum.Next(assembliesCount, assemblies, out actualAssembliesCount); var result = new List<DebugAssembly>((int)actualAssembliesCount); for (int i = 0; i < actualAssembliesCount; i++) { result.Add(new DebugAssembly(assemblies[i])); } return result; }
internal void AssemblyUnloaded(ICorDebugAssembly comAssembly) { var assembly = assemblies.TryGet(comAssembly); if (assembly == null) return; assembly.SetHasUnloaded(); assemblies.Remove(comAssembly); }
DnAssembly CreateAssembly(ICorDebugAssembly comAssembly, int id) { return new DnAssembly(this, comAssembly, id); }
DnAssembly CreateAssembly(ICorDebugAssembly comAssembly) { return new DnAssembly(this, comAssembly, Debugger.GetNextAssemblyId(), Process.GetNextAssemblyId(), Interlocked.Increment(ref nextAssemblyId)); }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { EnterCallback(PausedReason.Other, "UnloadAssembly", pAppDomain); ExitCallback(); }
public virtual void UnloadAssembly(ICorDebugAppDomain appDomain, ICorDebugAssembly assembly) { this.DefaultHandler(appDomain); }
int ICorDebugModule2.ResolveAssembly(uint tkAssemblyRef, out ICorDebugAssembly ppAssembly) { ppAssembly = null; return(COM_HResults.S_OK); }
public UnloadAssemblyDebugCallbackEventArgs(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) : base(pAppDomain, pAssembly) { }
void ICorDebugManagedCallback.UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { var ev = new CorEventArgs(new CorAppDomain(pAppDomain, p_options)); GetOwner(ev.Controller).DispatchEvent(ev); FinishEvent(ev); }
protected AssemblyDebugCallbackEventArgs(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) : base(pAppDomain) { this.AppDomain = pAppDomain; this.Assembly = pAssembly; }
public void UnloadAssembly(ICorDebugAppDomain appDomain, ICorDebugAssembly assy) { }
public void LoadAssembly(ICorDebugAppDomain appDomain, ICorDebugAssembly assy) { MessageBox.Show("Load assy: " + assy); }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { ManagedCallback managedCallback = GetProcessCallbackInterface("UnloadAssembly", pAppDomain); if (managedCallback != null) { managedCallback.UnloadAssembly(pAppDomain, pAssembly); } }
internal RuntimeAssembly(RuntimeAppDomain domain, ICorDebugAssembly comAssembly) { _domain = domain; _comAssembly = comAssembly; }
internal DnAssembly(DnAppDomain appDomain, ICorDebugAssembly assembly, int uniqueId, int uniqueIdProcess, int uniqueIdAppDomain) { AppDomain = appDomain; modules = new DebuggerCollection<ICorDebugModule, DnModule>(CreateModule); CorAssembly = new CorAssembly(assembly); UniqueId = uniqueId; UniqueIdProcess = uniqueIdProcess; UniqueIdAppDomain = uniqueIdAppDomain; }
internal DebuggedAssembly(ICorDebugAssembly a) { m_asm = a; }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { var assembly = new DebugAssembly(pAssembly); Logger.WriteLine("Unloaded {0} assembly", assembly.Name); pAppDomain.Continue(0); }
int ICorDebugModule.GetAssembly( out ICorDebugAssembly ppAssembly ) { ppAssembly = this; return Utility.COM_HResults.S_OK; }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { try { _EnterCallback(); _CallbackNotImplemented(); _CallbackEvent("UnloadAssembly"); } catch (Exception e) { _CallbackException(e); } }
public void UnloadAssembly([In, MarshalAs(UnmanagedType.Interface)] ICorDebugAppDomain pAppDomain, [In, MarshalAs(UnmanagedType.Interface)] ICorDebugAssembly pAssembly) { throw new NotImplementedException(); }
int ICorDebugModule.GetName(uint cchName, IntPtr pcchName, IntPtr szName) { return(ICorDebugAssembly.GetName(cchName, pcchName, szName)); }
internal RuntimeAssembly GetAssembly(ICorDebugAssembly assembly) { return(_assemblies[assembly]); }
internal DebugAssembly(ICorDebugAssembly assembly) { this.assembly = assembly; }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { EnterCallback("UnloadAssembly", pAppDomain); ExitCallback(); }
int ICorDebugModule2.ResolveAssembly( uint tkAssemblyRef, out ICorDebugAssembly ppAssembly ) { ppAssembly = null; return Utility.COM_HResults.S_OK; }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { controller.Continue(0); }
internal RuntimeAssembly GetAssembly(ICorDebugAssembly assembly) { return _assemblies[assembly]; }
internal CorAssembly (ICorDebugAssembly managedAssembly) :base(managedAssembly) { m_asm = managedAssembly; }
/// <summary> /// Gets an Assembly or null /// </summary> /// <param name="comAssembly">Assembly</param> /// <returns></returns> public DnAssembly TryGetAssembly(ICorDebugAssembly comAssembly) { Debugger.DebugVerifyThread(); return assemblies.TryGet(comAssembly); }
internal DnAssembly TryAdd(ICorDebugAssembly comAssembly) { return assemblies.Add(comAssembly); }
public virtual void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { pAppDomain.Continue(0); }
public static void ResolveAssembly(this ICorDebugModule2 instance, uint tkAssemblyRef, ref ICorDebugAssembly ppAssembly) { instance.__ResolveAssembly(tkAssemblyRef, ref ppAssembly); }
void ICorDebugManagedCallback.UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { var ev = new CorEventArgs(GetCachedAppDomain(pAppDomain), "UnloadAssembly"); GetOwner(ev.Controller).DispatchEvent(ev); FinishEvent(ev); }
internal DnAssembly TryAdd(ICorDebugAssembly comAssembly) { return(assemblies.Add(comAssembly)); }
DnAssembly CreateAssembly(ICorDebugAssembly comAssembly, int id) { return(new DnAssembly(this, comAssembly, id)); }
public DnAssembly TryGetAssembly(ICorDebugAssembly comAssembly) { Debugger.DebugVerifyThread(); return(assemblies.TryGet(comAssembly)); }
public void AssemblyLoad_Unload(ICorDebugAppDomain appDomain, ICorDebugAssembly assembly,bool action) { AssemblyNotification(new CorDebugAppDomain(appDomain),new CorAssembly(assembly), action); }
DnAssembly CreateAssembly(ICorDebugAssembly comAssembly) => new DnAssembly(this, comAssembly, Debugger.GetNextAssemblyId(), Process.GetNextAssemblyId(), Interlocked.Increment(ref nextAssemblyId));
public void LoadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { try { _EnterCallback(); lock (dbgproc) { dbgproc.iassemblies.Add(pAssembly); } _ResumeCallback(); _CallbackEvent("LoadAssembly"); } catch (Exception e) { _CallbackException(e); } }
internal DnAssembly TryAdd(ICorDebugAssembly comAssembly) => assemblies.Add(comAssembly);
int ICorDebugModule.GetAssembly(out ICorDebugAssembly ppAssembly) { ppAssembly = this; return(Utility.COM_HResults.S_OK); }
void ICorDebugManagedCallback.UnloadAssembly( ICorDebugAppDomain appDomain, ICorDebugAssembly assembly) { HandleEvent(ManagedCallbackType.OnAssemblyUnload, new CorAssemblyEventArgs( appDomain == null ? null : new CorAppDomain(appDomain), assembly == null ? null : new CorAssembly(assembly), ManagedCallbackType.OnAssemblyUnload)); }
public void UnloadAssembly(ICorDebugAppDomain pAppDomain, ICorDebugAssembly pAssembly) { Console.WriteLine("UnloadAssembly"); pAppDomain.Continue(0); }