3
* Copyright (C) 2003 Vivien Malerba
5
* This program is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU General Public License as
7
* published by the Free Software Foundation; either version 2 of the
8
* License, or (at your option) any later version.
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
15
* You should have received a copy of the GNU General Public License
16
* along with this program; if not, write to the Free Software
17
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
22
#ifndef __MG_DB_TABLE_H_
23
#define __MG_DB_TABLE_H_
27
#include <libgda/libgda.h>
31
#define MG_DB_TABLE_TYPE (mg_db_table_get_type())
32
#define MG_DB_TABLE(obj) G_TYPE_CHECK_INSTANCE_CAST (obj, mg_db_table_get_type(), MgDbTable)
33
#define MG_DB_TABLE_CLASS(klass) G_TYPE_CHECK_CLASS_CAST (klass, mg_db_table_get_type (), MgDbTableClass)
34
#define IS_MG_DB_TABLE(obj) G_TYPE_CHECK_INSTANCE_TYPE (obj, mg_db_table_get_type ())
38
extern GQuark mg_db_table_error_quark (void);
39
#define MG_DB_TABLE_ERROR mg_db_table_error_quark ()
43
MG_DB_TABLE_XML_LOAD_ERROR,
44
MG_DB_TABLE_META_DATA_UPDATE,
45
MG_DB_TABLE_FIELDS_ERROR
49
/* struct for the object's data */
53
MgDbTablePrivate *priv;
56
/* struct for the object's class */
57
struct _MgDbTableClass
62
void (*templ_signal) (MgDbTable *obj);
65
guint mg_db_table_get_type (void);
66
GObject *mg_db_table_new (MgConf *conf);
68
MgDatabase *mg_db_table_get_database (MgDbTable *table);
69
gboolean mg_db_table_is_view (MgDbTable *table);
70
const GSList *mg_db_table_get_parents (MgDbTable *table);
71
GSList *mg_db_table_get_constraints (MgDbTable *table);
72
MgDbConstraint *mg_db_table_get_pk_constraint (MgDbTable *table);
74
MgConf *mg_db_table_get_conf (MgDbTable *table);
76
gboolean mg_db_table_update_dbms_data (MgDbTable *table, GError **error);