GdaError

Name

GdaError -- Functions for managing errors

Synopsis



struct      GdaErrorPrivate;
GdaError*   gda_error_new                   (void);
void        gda_error_free                  (GdaError *error);
GList*      gda_error_list_copy             (const GList *errors);
void        gda_error_list_free             (GList *errors);
const gchar* gda_error_get_description      (GdaError *error);
void        gda_error_set_description       (GdaError *error,
                                             const gchar *description);
const glong gda_error_get_number            (GdaError *error);
void        gda_error_set_number            (GdaError *error,
                                             glong number);
const gchar* gda_error_get_source           (GdaError *error);
void        gda_error_set_source            (GdaError *error,
                                             const gchar *source);
const gchar* gda_error_get_sqlstate         (GdaError *error);
void        gda_error_set_sqlstate          (GdaError *error,
                                             const gchar *sqlstate);

Description

Details

struct GdaErrorPrivate

struct GdaErrorPrivate;


gda_error_new ()

GdaError*   gda_error_new                   (void);

Returns :


gda_error_free ()

void        gda_error_free                  (GdaError *error);

Frees the memory allocated by the error object.

error :

the error object.


gda_error_list_copy ()

GList*      gda_error_list_copy             (const GList *errors);

Creates a new list which contains the same errors as errors and adds a reference for each error in the list.

You must free the list using gda_error_list_free

errors :

a glist holding error objects.

Returns :

a list of errors


gda_error_list_free ()

void        gda_error_list_free             (GList *errors);

Frees all error objects in the list and the list itself. After this function has been called, the errors parameter doesn't point to valid storage any more.

errors :

a glist holding error objects.


gda_error_get_description ()

const gchar* gda_error_get_description      (GdaError *error);

error :

Returns :


gda_error_set_description ()

void        gda_error_set_description       (GdaError *error,
                                             const gchar *description);

error :

description :


gda_error_get_number ()

const glong gda_error_get_number            (GdaError *error);

error :

Returns :


gda_error_set_number ()

void        gda_error_set_number            (GdaError *error,
                                             glong number);

error :

number :


gda_error_get_source ()

const gchar* gda_error_get_source           (GdaError *error);

error :

Returns :


gda_error_set_source ()

void        gda_error_set_source            (GdaError *error,
                                             const gchar *source);

error :

source :


gda_error_get_sqlstate ()

const gchar* gda_error_get_sqlstate         (GdaError *error);

error :

Returns :


gda_error_set_sqlstate ()

void        gda_error_set_sqlstate          (GdaError *error,
                                             const gchar *sqlstate);

error :

error code

sqlstate :

SQL State, the error message to be associated with the error.