/// <summary> /// Constructs a new breakoint in the debugged process. /// </summary> /// <param name="breakpointCollection">A collection that holds programs breakpoints.</param> /// <param name="location">An object that is capable of resolving breakpoint location.</param> public MDbgFunctionBreakpoint(MDbgBreakpointCollection breakpointCollection, ISequencePointResolver location) : base(breakpointCollection) { m_location = location; Bind(); if (breakpointCollection != null) { breakpointCollection.NotifyChanged(this); } }
internal MDbgBreakpoint(MDbgBreakpointCollection breakpointCollection) { m_breakpointCollection = breakpointCollection; if (m_breakpointCollection != null) { m_breakpointNum = m_breakpointCollection.Register(this); // Now that the number + breakpoint collection properties have been set, // this bp is sufficiently initialized to fire the "Add" event. m_breakpointCollection.FireAddBreakpointEvent(this); } else { m_breakpointNum = 0; } }
/// <summary>Creates an empty process object. /// This object can be used to start a debugging session by calling /// CreateProcess or Attach method on it. /// </summary> /// <param name="engine">Root engine object that manages this process.</param> /// <param name="debugger">CorDebugger object that will be used to do an actual /// debugging</param> public MDbgProcess(MDbgEngine engine, CorDebug.CorDebugger debugger) { Debug.Assert(engine != null && debugger != null); if (engine == null) throw new ArgumentException("Value cannot be null.", "engine"); if (debugger == null) throw new ArgumentException("Value cannot be null.", "debugger"); m_engine = engine; m_threadMgr = new MDbgThreadCollection(this); m_appDomainMgr = new MDbgAppDomainCollection(this); m_moduleMgr = new MDbgModuleCollection(this); m_breakpointMgr = new MDbgBreakpointCollection(this); m_debuggerVarMgr = new MDbgDebuggerVarCollection(this); m_corDebugger = debugger; // we'll register as last code, so that other fields are already registered. m_number = engine.Processes.RegisterProcess(this); }