Top | ![]() |
![]() |
![]() |
![]() |
void | debugger-ready | Run Last |
void | debugger-started | Run Last |
void | debugger-stopped | Run Last |
void | frame-changed | Run Last |
void | program-exited | Run Last |
void | program-loaded | Run Last |
void | program-moved | Run Last |
void | program-running | Run Last |
void | program-stopped | Run Last |
void | sharedlib-event | Run Last |
void | signal-received | Run Last |
enum | IAnjutaDebuggerError |
enum | IAnjutaDebuggerOutputType |
enum | IAnjutaDebuggerState |
struct | IAnjutaDebuggerFrame |
GEnum ├── IAnjutaDebuggerError ├── IAnjutaDebuggerOutputType ╰── IAnjutaDebuggerState GInterface ╰── IAnjutaDebugger
This interface is implemented by debugger backends, by example the gdb backend. It is used by the debug manager plugin which provides the graphical interface and a simple wrapper: IAnjutaDebugManager.
The debugger is in one on these 5 states and emit a signal to the debug manager when it changes. Here is figure showing all transitions and the signal emitted.
void (*IAnjutaDebuggerCallback) (const gpointer data
,gpointer user_data
,GError *err
);
This callback function is used only by ianjuta_debugger_callback with a NULL data.
void (*IAnjutaDebuggerGListCallback) (const GList *list
,gpointer user_data
,GError *err
);
This callback function is used by several debugger functions. Depending on the function, the kind of elements in the list is different. It is a string for ianjuta_debugger_list_local or a IAnjutaDebuggerFrame for ianjuta_debugger_list_frame.
list |
list of data. |
[element-type any] |
user_data |
user data passed to the function |
|
err |
error |
void (*IAnjutaDebuggerGCharCallback) (const gchar *value
,gpointer user_data
,GError *err
);
This callback function is used by several debugger functions. The data is a string
void (*IAnjutaDebuggerOutputCallback) (IAnjutaDebuggerOutputType type
,const gchar *output
,gpointer user_data
);
This callback function is used only by ianjuta_debugger_callback with a NULL data.
gboolean ianjuta_debugger_abort (IAnjutaDebugger *obj
,GError **err
);
Quit the debugger as fast as possible.
gboolean ianjuta_debugger_attach (IAnjutaDebugger *obj
,pid_t pid
,const GList *source_search_directories
,GError **err
);
Attach to an already running process.
obj |
Self |
|
pid |
pid of the process to debug |
|
source_search_directories |
List of directories to search for source files. |
[element-type utf8] |
err |
Error propagation and reporting. |
gboolean ianjuta_debugger_callback (IAnjutaDebugger *obj
,IAnjutaDebuggerCallback callback
,gpointer user_data
,GError **err
);
All commands are executed asynchronously and give back information with callbacks. It is difficult to know when a command is really executed. But as all commands are executed in order, you can use this command to get a call back when all previous commands have been executed.
gboolean ianjuta_debugger_connect (IAnjutaDebugger *obj
,const gchar *server
,const gchar *args
,gboolean terminal
,gboolean stop
,GError **err
);
Connect to a remote debugger and run program
void ianjuta_debugger_disable_log (IAnjutaDebugger *obj
,GError **err
);
Disable debugger log.
gboolean ianjuta_debugger_dump_stack_trace (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Return a stack trace valid for a bug reports. This function is optional.
void ianjuta_debugger_enable_log (IAnjutaDebugger *obj
,IAnjutaMessageView *log
,GError **err
);
Log all debuggers commands, mainly useful for debugging.
gboolean ianjuta_debugger_evaluate (IAnjutaDebugger *obj
,const gchar *name
,const gchar *value
,IAnjutaDebuggerGCharCallback callback
,gpointer user_data
,GError **err
);
Change the value of a variable in the current program.
gboolean ianjuta_debugger_exit (IAnjutaDebugger *obj
,GError **err
);
Exit from the currently loaded program.
IAnjutaDebuggerState ianjuta_debugger_get_state (IAnjutaDebugger *obj
,GError **err
);
Get the current state of the debugger
gboolean ianjuta_debugger_handle_signal (IAnjutaDebugger *obj
,const gchar *name
,gboolean stop
,gboolean print
,gboolean ignore
,GError **err
);
It defines how to handle signal received by the program.
gboolean ianjuta_debugger_info_args (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some informatin about a current functin arguments. This function has been deprecated and is not used anymore in the debugger GUI.
gboolean ianjuta_debugger_info_frame (IAnjutaDebugger *obj
,guint frame
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some information about the one stack frame. This function has been deprecated and is not used anymore in the debugger GUI.
gboolean ianjuta_debugger_info_program (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some informatin about a current program. This function has been deprecated and is not used anymore in the debugger GUI.
gboolean ianjuta_debugger_info_sharedlib (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get information about shared libraries.
gboolean ianjuta_debugger_info_signal (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some informatin about a signal
gboolean ianjuta_debugger_info_target (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get back some information about the target This function has been deprecated and is not used anymore in the debugger GUI.
gboolean ianjuta_debugger_info_thread (IAnjutaDebugger *obj
,gint thread
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some information about current threads.
gboolean ianjuta_debugger_info_udot (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some informatin about OS structures. This function has been deprecated and is not used anymore in the debugger GUI.
gboolean ianjuta_debugger_info_variables (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get some informatin about variables. This function has been deprecated and is not used anymore in the debugger GUI.
gboolean ianjuta_debugger_inspect (IAnjutaDebugger *obj
,const gchar *name
,IAnjutaDebuggerGCharCallback callback
,gpointer user_data
,GError **err
);
Get back the value of the named variable.
gboolean ianjuta_debugger_interrupt (IAnjutaDebugger *obj
,GError **err
);
Interrupt the program currently running.
gboolean ianjuta_debugger_list_argument (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get the list of arguments
gboolean ianjuta_debugger_list_frame (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get the list of frames.
obj |
Self |
|
callback |
Callback to call getting a list of IAnjutaDebuggerFrame |
|
user_data |
User data that is passed back to the callback |
|
err |
Error propagation and reporting. |
gboolean ianjuta_debugger_list_local (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get the list of local variables
gboolean ianjuta_debugger_list_thread (IAnjutaDebugger *obj
,IAnjutaDebuggerGListCallback callback
,gpointer user_data
,GError **err
);
Get the list of threads.
obj |
Self |
|
callback |
Callback to call getting a list of IAnjutaDebuggerFrame for each thread |
|
user_data |
User data that is passed back to the callback |
|
err |
Error propagation and reporting. |
gboolean ianjuta_debugger_load (IAnjutaDebugger *obj
,const gchar *file
,const gchar *mime_type
,const GList *source_search_directories
,GError **err
);
Load a program in the debugger.
obj |
Self |
|
file |
filename |
|
mime_type |
mime type of the file |
|
source_search_directories |
List of directories to search for source files. |
[element-type utf8] |
err |
Error propagation and reporting. |
gboolean ianjuta_debugger_print (IAnjutaDebugger *obj
,const gchar *name
,IAnjutaDebuggerGCharCallback callback
,gpointer user_data
,GError **err
);
Display value of a variable, like inspect.
gboolean ianjuta_debugger_quit (IAnjutaDebugger *obj
,GError **err
);
Quit the debugger, can wait until the debugger is ready.
gboolean ianjuta_debugger_run (IAnjutaDebugger *obj
,GError **err
);
Run the program currently loaded.
gboolean ianjuta_debugger_run_from (IAnjutaDebugger *obj
,const gchar *file
,gint line
,GError **err
);
Execute the program from a new position. This function is optional.
gboolean ianjuta_debugger_run_to (IAnjutaDebugger *obj
,const gchar *file
,gint line
,GError **err
);
Execute the currently loaded program until it reachs the target line.
gboolean ianjuta_debugger_send_command (IAnjutaDebugger *obj
,const gchar *command
,GError **err
);
Send a command directly to the debugger. Warning, changing the debugger states, by sending a run command by example, will probably gives some troubles in the debug manager.
gboolean ianjuta_debugger_set_environment (IAnjutaDebugger *obj
,gchar **env
,GError **err
);
Set environment variable
gboolean ianjuta_debugger_set_frame (IAnjutaDebugger *obj
,guint frame
,GError **err
);
Set the current frame.
gboolean ianjuta_debugger_set_thread (IAnjutaDebugger *obj
,gint thread
,GError **err
);
Set the current thread.
gboolean ianjuta_debugger_set_working_directory (IAnjutaDebugger *obj
,const gchar *dir
,GError **err
);
Set program working directory.
gboolean ianjuta_debugger_start (IAnjutaDebugger *obj
,const gchar *args
,gboolean terminal
,gboolean stop
,GError **err
);
Start a loaded program under debugger control.
gboolean ianjuta_debugger_step_in (IAnjutaDebugger *obj
,GError **err
);
Execute a single C instruction of the program currently loaded.
gboolean ianjuta_debugger_step_out (IAnjutaDebugger *obj
,GError **err
);
Execute the currently loaded program until it goes out of the current procedure.
gboolean ianjuta_debugger_step_over (IAnjutaDebugger *obj
,GError **err
);
Execute one C instruction, without entering in procedure, of the program currently loaded.
gboolean ianjuta_debugger_unload (IAnjutaDebugger *obj
,GError **err
);
Unload a program.
This enumeration is used to defined the error returned by the debugger backend.
No error |
||
Debugger is not ready to execute the command |
||
Debugger is not is running state |
||
Debugger is not is stopped state |
||
Debugger is not is loaded state |
||
Debugger is not in started state |
||
Debugger is not connected: |
||
Corresponding function is not implemented |
||
Operation has been cancelled |
||
Debugger cannot create variable |
||
Debugger cannot access memory |
||
Debugger cannot open file |
||
Debugger cannot debug such file |
||
Debugger is too old |
||
Debugger cannot be found |
||
Command has already been executed |
||
Program cannot be found |
||
Unable to connect to debugger |
||
Unknown error |
||
other error |
This enumeration is used to defined the kind of output in IAnjutaDebuggerOutputCallback
This enumeration is used to defined the different state of the debugger.
struct IAnjutaDebuggerFrame { gint thread; guint level; gchar *args; gchar *file; guint line; gchar *function; gchar *library; gulong address; };
This structure keeps all information about a stack frame.
“debugger-ready”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, IAnjutaDebuggerState arg1, gpointer user_data)
Flags: Run Last
“debugger-started”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gpointer user_data)
Flags: Run Last
“debugger-stopped”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, GError *arg1, gpointer user_data)
Flags: Run Last
“frame-changed”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, guint arg1, gint arg2, gpointer user_data)
Flags: Run Last
“program-exited”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gpointer user_data)
Flags: Run Last
“program-loaded”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gpointer user_data)
Flags: Run Last
“program-moved”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gint arg1, gint arg2, gulong arg3, gchar *arg4, guint arg5, gpointer user_data)
Flags: Run Last
“program-running”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gpointer user_data)
Flags: Run Last
“program-stopped”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gpointer user_data)
Flags: Run Last
“sharedlib-event”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gpointer user_data)
Flags: Run Last
“signal-received”
signalvoid user_function (IAnjutaDebugger *ianjutadebugger, gchar *arg1, gchar *arg2, gpointer user_data)
Flags: Run Last