Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: c33c5b0bb2eadbb5c7fbda3d04e00e05ef99fbf3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
/*******************************************************************************
 * Copyright (c) 2010, 2012 Wind River Systems and others.
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 * 
 * Contributors:
 *     Wind River Systems - initial API and implementation
 *******************************************************************************/
package org.eclipse.cdt.dsf.debug.service;

import org.eclipse.cdt.dsf.concurrent.DataRequestMonitor;
import org.eclipse.cdt.dsf.debug.service.IRunControl.IExecutionDMContext;
import org.eclipse.cdt.dsf.debug.service.IRunControl.ISuspendedDMEvent;

/**
 * Extension to the Breakpoints service which adds support for correlating 
 * breakpoints and execution contexts.
 * @since 2.1
 */
public interface IBreakpointsExtension extends IBreakpoints {

    /**
     * Event indicating that a given thread or container was suspended
     * by the given breakpoint(s).
     */
    public interface IBreakpointHitDMEvent extends ISuspendedDMEvent {
        
        /**
         * Returns the breakpoints that suspended the thread.
         */
        IBreakpointDMContext[] getBreakpoints();
    }

    /**
     * If a given execution context was suspended due to hitting a breakpoint, 
     * this method should return the breakpoints which caused the thread or 
     * container to suspend.
     * <p>
     * If the given thread is not suspended or is not suspended at a 
     * breakpoint, an empty array or an error with an INVALID_STATE code 
     * will be returned. 
     * 
     * @param ctx Thread or container to get breakpoints for.
     * @param rm Breakpoints that the thread or container is suspended on.
     */
    public void getExecutionContextBreakpoints(IExecutionDMContext ctx, DataRequestMonitor<IBreakpointDMContext[]> rm);
}

Back to the top