int IDebugBreakpointBoundEvent2.EnumBoundBreakpoints(out IEnumDebugBoundBreakpoints2 ppEnum) { IDebugBoundBreakpoint2[] boundBreakpoints = new IDebugBoundBreakpoint2[1]; boundBreakpoints[0] = m_boundBreakpoint; ppEnum = new AD7BoundBreakpointsEnum(boundBreakpoints); return(EngineConstants.S_OK); }
// Enumerates all breakpoints bound from this pending breakpoint int IDebugPendingBreakpoint2.EnumBoundBreakpoints(out IEnumDebugBoundBreakpoints2 ppEnum) { lock (m_boundBreakpoints) { IDebugBoundBreakpoint2[] boundBreakpoints = m_boundBreakpoints.ToArray(); ppEnum = new AD7BoundBreakpointsEnum(boundBreakpoints); } return(EngineConstants.S_OK); }
public void OnBreakpoint(DebuggedThread thread, IDebugBoundBreakpoint2 bp, uint address) { IDebugBoundBreakpoint2[] boundBreakpoints = new IDebugBoundBreakpoint2[1]; boundBreakpoints[0] = bp; /*int i = 0; * foreach (object objCurrentBreakpoint in clients) * { * boundBreakpoints[i] = (IDebugBoundBreakpoint2)objCurrentBreakpoint; * i++; * }*/ // An engine that supports more advanced breakpoint features such as hit counts, conditions and filters // should notify each bound breakpoint that it has been hit and evaluate conditions here. // The sample engine does not support these features. AD7BoundBreakpointsEnum boundBreakpointsEnum = new AD7BoundBreakpointsEnum(boundBreakpoints); AD7BreakpointEvent eventObject = new AD7BreakpointEvent(boundBreakpointsEnum); //AD7Thread ad7Thread = (AD7Thread)thread.Client; Send(eventObject, AD7BreakpointEvent.IID, (IDebugThread2)thread); }