[libgdamm] Fixed the build with latest libgda.



commit 70cff4336cb90e2f006d06103bf65a700e3b0b1d
Author: Murray Cumming <murrayc murrayc com>
Date:   Thu May 20 00:00:58 2010 +0200

    Fixed the build with latest libgda.
    
    * libgda/src/libgda_methods.defs: Regenerated with h2defs.py
    * libgda/src/sqlbuilder.ccg: Adapted now that I have removed the id
    parameters from the C API.

 ChangeLog                      |    8 ++++++++
 libgda/src/libgda_methods.defs |   38 ++++++++++++++++++++++++--------------
 libgda/src/sqlbuilder.ccg      |   24 ++++++++++++------------
 3 files changed, 44 insertions(+), 26 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 78f02f3..cc159d9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2010-05-20  Murray Cumming  <murrayc murrayc com>
+
+	Fixed the build with latest libgda.
+	
+	* libgda/src/libgda_methods.defs: Regenerated with h2defs.py
+	* libgda/src/sqlbuilder.ccg: Adapted now that I have removed the id 
+	parameters from the C API.
+
 2010-05-17  Murray Cumming  <murrayc murrayc com>
 
     SqlBuilder: Don't pass empty strings to the C functions.
diff --git a/libgda/src/libgda_methods.defs b/libgda/src/libgda_methods.defs
index 478ba79..faeb37a 100644
--- a/libgda/src/libgda_methods.defs
+++ b/libgda/src/libgda_methods.defs
@@ -5217,7 +5217,6 @@
   (c-name "gda_sql_builder_add_id")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("const-gchar*" "string")
   )
 )
@@ -5227,7 +5226,6 @@
   (c-name "gda_sql_builder_add_expr")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("GdaDataHandler*" "dh")
     '("GType" "type")
   )
@@ -5239,7 +5237,6 @@
   (c-name "gda_sql_builder_add_expr_value")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("GdaDataHandler*" "dh")
     '("const-GValue*" "value")
   )
@@ -5250,7 +5247,6 @@
   (c-name "gda_sql_builder_add_param")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("const-gchar*" "param_name")
     '("GType" "type")
     '("gboolean" "nullok")
@@ -5262,7 +5258,6 @@
   (c-name "gda_sql_builder_add_cond")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("GdaSqlOperatorType" "op")
     '("guint" "op1")
     '("guint" "op2")
@@ -5275,7 +5270,6 @@
   (c-name "gda_sql_builder_add_cond_v")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("GdaSqlOperatorType" "op")
     '("const-guint*" "op_ids")
     '("gint" "op_ids_size")
@@ -5287,7 +5281,6 @@
   (c-name "gda_sql_builder_add_function")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("const-gchar*" "func_name")
   )
   (varargs #t)
@@ -5298,7 +5291,6 @@
   (c-name "gda_sql_builder_add_function_v")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("const-gchar*" "func_name")
     '("const-guint*" "args")
     '("gint" "args_size")
@@ -5310,7 +5302,6 @@
   (c-name "gda_sql_builder_add_sub_select")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("GdaSqlStatement*" "sqlst")
   )
 )
@@ -5320,7 +5311,6 @@
   (c-name "gda_sql_builder_add_case")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("guint" "test_expr")
     '("guint" "else_expr")
   )
@@ -5332,7 +5322,6 @@
   (c-name "gda_sql_builder_add_case_v")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("guint" "test_expr")
     '("guint" "else_expr")
     '("const-guint*" "when_array")
@@ -5416,7 +5405,6 @@
   (c-name "gda_sql_builder_select_add_target_id")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("guint" "table_id")
     '("const-gchar*" "alias")
   )
@@ -5427,7 +5415,6 @@
   (c-name "gda_sql_builder_select_join_targets")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("guint" "left_target_id")
     '("guint" "right_target_id")
     '("GdaSqlSelectJoinType" "join_type")
@@ -5526,7 +5513,6 @@
   (c-name "gda_sql_builder_import_expression")
   (return-type "guint")
   (parameters
-    '("guint" "id")
     '("GdaSqlExpr*" "expr")
   )
 )
@@ -6227,6 +6213,18 @@
   )
 )
 
+(define-function gda_compute_unique_table_row_condition_with_cnc
+  (c-name "gda_compute_unique_table_row_condition_with_cnc")
+  (return-type "GdaSqlExpr*")
+  (parameters
+    '("GdaConnection*" "cnc")
+    '("GdaSqlStatementSelect*" "stsel")
+    '("GdaMetaTable*" "mtable")
+    '("gboolean" "require_pk")
+    '("GError**" "error")
+  )
+)
+
 (define-function gda_compute_dml_statements
   (c-name "gda_compute_dml_statements")
   (return-type "gboolean")
@@ -7112,6 +7110,11 @@
 
 ;; From gda-statement-struct.h
 
+(define-function gda_sql_statement_get_type
+  (c-name "gda_sql_statement_get_type")
+  (return-type "GType")
+)
+
 (define-function gda_sql_statement_new
   (c-name "gda_sql_statement_new")
   (is-constructor-of "GdaSqlStatement")
@@ -7258,6 +7261,11 @@
 
 ;; From gda-statement-struct-parts.h
 
+(define-function gda_sql_expr_get_type
+  (c-name "gda_sql_expr_get_type")
+  (return-type "GType")
+)
+
 (define-function gda_sql_expr_new
   (c-name "gda_sql_expr_new")
   (is-constructor-of "GdaSqlExpr")
@@ -7965,3 +7973,5 @@
     '("const-GValue*" "value")
   )
 )
+
+
diff --git a/libgda/src/sqlbuilder.ccg b/libgda/src/sqlbuilder.ccg
index 6d67437..5de1ffa 100644
--- a/libgda/src/sqlbuilder.ccg
+++ b/libgda/src/sqlbuilder.ccg
@@ -47,47 +47,47 @@ SqlBuilder::SqlBuilder(SqlStatementType type)
 
 guint SqlBuilder::add_sub_select(const SqlStatement& sqlst)
 {
-  return gda_sql_builder_add_sub_select(gobj(), 0, const_cast<GdaSqlStatement*>(sqlst.gobj()));
+  return gda_sql_builder_add_sub_select(gobj(), const_cast<GdaSqlStatement*>(sqlst.gobj()));
 }
 
 guint SqlBuilder::add_id(const Glib::ustring& string)
 {
-  return gda_sql_builder_add_id(gobj(), 0, string.c_str());
+  return gda_sql_builder_add_id(gobj(), string.c_str());
 }
 
 guint SqlBuilder::add_expr_as_value(const Glib::RefPtr<DataHandler>& dh, const Value& value)
 {
-  return gda_sql_builder_add_expr_value(gobj(), 0, dh->gobj(), const_cast<GValue*>(value.gobj()));
+  return gda_sql_builder_add_expr_value(gobj(), dh->gobj(), const_cast<GValue*>(value.gobj()));
 }
 
 guint SqlBuilder::add_expr_as_value(const Value& value)
 {
-  return gda_sql_builder_add_expr_value(gobj(), 0, 0, const_cast<GValue*>(value.gobj()));
+  return gda_sql_builder_add_expr_value(gobj(), 0, const_cast<GValue*>(value.gobj()));
 }
 
 guint SqlBuilder::add_param(const Glib::ustring& param_name, GType type, bool nullok)
 {
-  return gda_sql_builder_add_param(gobj(), 0, param_name.c_str(), type, nullok);
+  return gda_sql_builder_add_param(gobj(), param_name.c_str(), type, nullok);
 }
 
 guint SqlBuilder::add_cond(SqlOperatorType op, guint op1, guint op2, guint op3)
 {
-  return gda_sql_builder_add_cond(gobj(), 0, (GdaSqlOperatorType) op, op1, op2, op3);
+  return gda_sql_builder_add_cond(gobj(), (GdaSqlOperatorType) op, op1, op2, op3);
 }
 
 guint SqlBuilder::add_cond(SqlOperatorType op, const Glib::ArrayHandle<guint>& op_ids)
 {
-  return gda_sql_builder_add_cond_v(gobj(), 0, (GdaSqlOperatorType) op, op_ids.data(), op_ids.size());
+  return gda_sql_builder_add_cond_v(gobj(), (GdaSqlOperatorType) op, op_ids.data(), op_ids.size());
 }
 
 guint SqlBuilder::add_function(const Glib::ustring& function_name, const Glib::ArrayHandle<guint>& args)
 {
-  return gda_sql_builder_add_function_v(gobj(), 0, function_name.c_str(), args.data(), args.size());
+  return gda_sql_builder_add_function_v(gobj(), function_name.c_str(), args.data(), args.size());
 }
 
 guint SqlBuilder::add_function(const Glib::ustring& function_name, guint arg)
 {
-  return gda_sql_builder_add_function(gobj(), 0, function_name.c_str(), arg, 0, 0);
+  return gda_sql_builder_add_function(gobj(), function_name.c_str(), arg, 0, 0);
 }
 
 guint SqlBuilder::select_add_target(const Glib::ustring& table_name, const Glib::ustring& alias)
@@ -97,12 +97,12 @@ guint SqlBuilder::select_add_target(const Glib::ustring& table_name, const Glib:
 
 guint SqlBuilder::select_add_target_id(guint table_id, const Glib::ustring& alias)
 {
-  return gda_sql_builder_select_add_target_id(gobj(), 0, table_id, string_or_null(alias.c_str()));
+  return gda_sql_builder_select_add_target_id(gobj(), table_id, string_or_null(alias.c_str()));
 }
 
 guint SqlBuilder::select_join_targets(guint left_target_id, guint right_target_id, SqlSelectJoinType join_type, guint join_expr)
 {
-  return gda_sql_builder_select_join_targets(gobj(), 0, left_target_id, right_target_id, (GdaSqlSelectJoinType) join_type, join_expr);
+  return gda_sql_builder_select_join_targets(gobj(), left_target_id, right_target_id, (GdaSqlSelectJoinType) join_type, join_expr);
 }
 
 void SqlBuilder::select_set_distinct(bool distinct)
@@ -124,7 +124,7 @@ void SqlBuilder::select_set_limit(guint limit_count, guint offset)
 
 guint SqlBuilder::import_expression(const SqlExpr& expr)
 {
-  return gda_sql_builder_import_expression(gobj(), 0, const_cast<GdaSqlExpr*>((expr).gobj()));
+  return gda_sql_builder_import_expression(gobj(), const_cast<GdaSqlExpr*>((expr).gobj()));
 }
 
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]