GdaThread

Name

GdaThread -- Thread support functions

Synopsis



gpointer    (*GdaThreadFunc)                (GdaThread *thr,
                                             gpointer user_data);
GdaThread*  gda_thread_new                  (GdaThreadFunc func);
void        gda_thread_free                 (GdaThread *thr);
void        gda_thread_start                (GdaThread *thr,
                                             gpointer user_data);
void        gda_thread_stop                 (GdaThread *thr);
gboolean    gda_thread_is_running           (GdaThread *thr);

Description

This module (still in development, DON'T USE IT) provides a convenient way of adding multithread support to GDA applications. As with some other libgda-common modules, this is intended to be used internally in other GDA parts, but it is also made available for GDA application supports.

Using this module will allow you to forget about the actual thread implementation available on your system.

Details

GdaThreadFunc ()

gpointer    (*GdaThreadFunc)                (GdaThread *thr,
                                             gpointer user_data);

thr :

user_data :

Returns :


gda_thread_new ()

GdaThread*  gda_thread_new                  (GdaThreadFunc func);

Create a new GdaThread object. This function just creates the internal structures and initializes all the data, but does not start the thread. To do so, you must use gda_thread_start.

func :

function to be called

Returns :


gda_thread_free ()

void        gda_thread_free                 (GdaThread *thr);

thr :


gda_thread_start ()

void        gda_thread_start                (GdaThread *thr,
                                             gpointer user_data);

thr :

a GdaThread object

user_data :

data to pass to signals


gda_thread_stop ()

void        gda_thread_stop                 (GdaThread *thr);

thr :


gda_thread_is_running ()

gboolean    gda_thread_is_running           (GdaThread *thr);

Checks whether the given thread object is running or not

thr :

a GdaThread object

Returns :