## IAnjutaDebuggerBreakpoint

IAnjutaDebuggerBreakpoint — Breakpoint Debugger interface

## Stability Level

Unstable, unless otherwise indicated

## Functions

void | ( *IAnjutaDebuggerBreakpointCallback ) ()
GQuark | ianjuta_debugger_breakpoint_error_quark ()
gboolean | ianjuta_debugger_breakpoint_clear_breakpoint ()
gboolean | ianjuta_debugger_breakpoint_condition_breakpoint ()
gboolean | ianjuta_debugger_breakpoint_enable_breakpoint ()
gboolean | ianjuta_debugger_breakpoint_ignore_breakpoint ()
gint | ianjuta_debugger_breakpoint_implement_breakpoint ()
gboolean | ianjuta_debugger_breakpoint_list_breakpoint ()
gboolean | ianjuta_debugger_breakpoint_set_breakpoint_at_address ()
gboolean | ianjuta_debugger_breakpoint_set_breakpoint_at_function ()
gboolean | ianjuta_debugger_breakpoint_set_breakpoint_at_line ()

## Types and Values

#define | IANJUTA_DEBUGGER_BREAKPOINT_ERROR
enum | IAnjutaDebuggerBreakpointMethod
enum | IAnjutaDebuggerBreakpointType
struct | IAnjutaDebuggerBreakpointItem

## Object Hierarchy

        GEnum
        ├── IAnjutaDebuggerBreakpointMethod
        ╰── IAnjutaDebuggerBreakpointType
        GInterface
        ╰── IAnjutaDebuggerBreakpoint

## Includes

    #include <libanjuta/interfaces/ianjuta-debugger-breakpoint.h>

## Description

## Functions

### IAnjutaDebuggerBreakpointCallback ()

    void
    (*IAnjutaDebuggerBreakpointCallback) (const IAnjutaDebuggerBreakpointItem *data,
                                          gpointer user_data,
                                          GError *err);

This callback function is used to return a IAnjutaBreakpointItem.

#### Parameters

data | a IAnjutaBreakpointItem object |
user_data | user data passed to the function |
err | error |

### ianjuta_debugger_breakpoint_error_quark ()

    GQuark
    ianjuta_debugger_breakpoint_error_quark
                                   (void);

### ianjuta_debugger_breakpoint_clear_breakpoint ()

    gboolean
    ianjuta_debugger_breakpoint_clear_breakpoint
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    guint id,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

Clear a breakpoint put by any set functions. The Id of the breakpoint is given in the callback of the set functions.

#### Parameters

obj | Self |
id | Breakpoint identification number |
callback | Callback to call when the breakpoint has been cleared |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_condition_breakpoint ()

    gboolean
    ianjuta_debugger_breakpoint_condition_breakpoint
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    guint id,
                                    const gchar *condition,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

Add a condition, evaluate in the program context, on the breakpoint, the program will stop when it reachs the breakpoint only if the condition is true. This function is optional.

#### Parameters

obj | Self |
id | Breakpoint identification number |
condition | expression that has to be true |
callback | Callback to call when the breakpoint has been changed |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_enable_breakpoint ()

    gboolean
    ianjuta_debugger_breakpoint_enable_breakpoint
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    guint id,
                                    gboolean enable,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

Enable of disable a breakpoint. This function is optional.

#### Parameters

obj | Self |
id | Breakpoint identification number |
enable | TRUE to enable the breakpoint, FALSE to disable it |
callback | Callback to call when the breakpoint has been changed |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_ignore_breakpoint ()

    gboolean
    ianjuta_debugger_breakpoint_ignore_breakpoint
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    guint id,
                                    guint ignore,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

This allow to ignore the breakpoint a number of time before stopping. This function is optional.

#### Parameters

obj | Self |
id | Breakpoint identification number |
ignore | Number of time a breakpoint must be ignored |
callback | Callback to call when the breakpoint has been changed |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_implement_breakpoint ()

    gint
    ianjuta_debugger_breakpoint_implement_breakpoint
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    GError **err);

Return all implemented methods.

#### Parameters

obj | Self |
err | Error propagation and reporting. |

#### Returns

A OR of IAnjutaDebuggerBreakpointMethod corresponding to all implemented optional methods.

### ianjuta_debugger_breakpoint_list_breakpoint ()

    gboolean
    ianjuta_debugger_breakpoint_list_breakpoint
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    IAnjutaDebuggerGListCallback callback,
                                    gpointer user_data,
                                    GError **err);

List all breakpoints set in the debugger. It is useful to know how many time a breakpoint has been hit.

#### Parameters

obj | Self |
callback | Callback to call with the list of IAnjutaDebuggreBreakpointItem |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_set_breakpoint_at_address ()

    gboolean
    ianjuta_debugger_breakpoint_set_breakpoint_at_address
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    gulong address,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

Set a breakpoint at the specified address. This function is optional.

#### Parameters

obj | Self |
address | Address of the breakpoint |
callback | Callback to call when the breakpoint has been set |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_set_breakpoint_at_function ()

    gboolean
    ianjuta_debugger_breakpoint_set_breakpoint_at_function
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    const gchar *file,
                                    const gchar *function,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

Set a breakpoint at the beginning of the specified function. This function is optional.

#### Parameters

obj | Self |
file | File containing the breakpoint |
function | Function name where the breakpoint is put |
callback | Callback to call when the breakpoint has been set |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

### ianjuta_debugger_breakpoint_set_breakpoint_at_line ()

    gboolean
    ianjuta_debugger_breakpoint_set_breakpoint_at_line
                                   (IAnjutaDebuggerBreakpoint *obj,
                                    const gchar *file,
                                    guint line,
                                    IAnjutaDebuggerBreakpointCallback callback,
                                    gpointer user_data,
                                    GError **err);

Set a breakpoint at the specified line in the file.

#### Parameters

obj | Self |
file | File containing the breakpoint |
line | Line number where is the breakpoint |
callback | Callback to call when the breakpoint has been set |
user_data | User data that is passed back to the callback |
err | Error propagation and reporting. |

#### Returns

TRUE if the request succeed and the callback is called. If FALSE, the callback will not be called.

## Types and Values

### IANJUTA_DEBUGGER_BREAKPOINT_ERROR

    #define IANJUTA_DEBUGGER_BREAKPOINT_ERROR ianjuta_debugger_breakpoint_error_quark()

### enum IAnjutaDebuggerBreakpointMethod

Defines which breakpoint characteristics are supported by the debugger backend.

#### Members

IANJUTA_DEBUGGER_BREAKPOINT_SET_AT_ADDRESS | Allow to set breakpoint on address |
IANJUTA_DEBUGGER_BREAKPOINT_SET_AT_FUNCTION | Allow to set breakpoint on function name |
IANJUTA_DEBUGGER_BREAKPOINT_ENABLE | Allow to disable breakpoint |
IANJUTA_DEBUGGER_BREAKPOINT_IGNORE | Allow to ignore breakpoint |
IANJUTA_DEBUGGER_BREAKPOINT_CONDITION | Allow to add a condition on breakpoint |

### enum IAnjutaDebuggerBreakpointType

This enumeration defined various characteristics of the breakpoint.

#### Members

IANJUTA_DEBUGGER_BREAKPOINT_REMOVED | Set for removed breakpoint |
IANJUTA_DEBUGGER_BREAKPOINT_UPDATED | Set for changed breakpoint |
IANJUTA_DEBUGGER_BREAKPOINT_ON_LINE | Set on source line |
IANJUTA_DEBUGGER_BREAKPOINT_ON_ADDRESS | Set on an addresse |
IANJUTA_DEBUGGER_BREAKPOINT_ON_FUNCTION | Set on a function name |
IANJUTA_DEBUGGER_BREAKPOINT_ON_READ | Set on read access |
IANJUTA_DEBUGGER_BREAKPOINT_ON_WRITE | Set on write access |
IANJUTA_DEBUGGER_BREAKPOINT_WITH_ENABLE | Has enable information |
IANJUTA_DEBUGGER_BREAKPOINT_WITH_IGNORE | Has ignore information, |
IANJUTA_DEBUGGER_BREAKPOINT_WITH_TIME | Has counter information |
IANJUTA_DEBUGGER_BREAKPOINT_WITH_CONDITION | Has a condition |
IANJUTA_DEBUGGER_BREAKPOINT_WITH_TEMPORARY | Temporary breakpoint, automatically removed when triggered |
IANJUTA_DEBUGGER_BREAKPOINT_WITH_PENDING | Pending breakpoint |

### struct IAnjutaDebuggerBreakpointItem

    struct IAnjutaDebuggerBreakpointItem {
    	gint type;
    	guint id;
    	gchar *file;
    	guint line;
    	gchar *function;
    	gulong address;
    	gboolean enable;
    	guint ignore;
    	guint times;
    	gchar *condition;
    	gboolean temporary;
    	gboolean pending;
    };

This structure keeps all information about a breakpoint.

#### Members

gint `type`; | type see IAnjutaBreakpointType enumeration |
guint `id`; | unique identifier |
gchar *`file`; | source file where is the breakpoint |
guint `line`; | corresponding source file line number |
gchar *`function`; | corresponding function name |
gulong `address`; | corresponding address |
gboolean `enable`; | TRUE if the breakpoint is enabled |
guint `ignore`; | TRUE if the breakpoint is ignored |
guint `times`; | Count how many time the breakpoint is triggered |
gchar *`condition`; | Additional condition for triggering the breakpoint |
gboolean `temporary`; | TRUE if the breakpoint is temporary |
gboolean `pending`; | TRUE if the breakpoint is pending |