[libgda] Modified annotations to generate better native bingings.
- From: Vivien Malerba <vivien src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgda] Modified annotations to generate better native bingings.
- Date: Wed, 3 Jun 2015 14:14:36 +0000 (UTC)
commit 43206eb0b3cabc55c391420fd29b2792638bb6ee
Author: Corentin Noël <corentin elementary io>
Date: Tue Jun 2 00:01:59 2015 +0200
Modified annotations to generate better native bingings.
libgda/Gda-6.0.metadata | 40 ++--------------------------------------
libgda/gda-data-handler.c | 6 +++---
libgda/gda-data-model-iter.c | 6 +++---
libgda/gda-data-model.c | 2 +-
libgda/gda-holder.c | 2 +-
libgda/gda-meta-store.c | 2 +-
libgda/gda-row.c | 2 +-
libgda/gda-set.c | 2 +-
libgda/gda-statement-extra.h | 2 +-
9 files changed, 14 insertions(+), 50 deletions(-)
---
diff --git a/libgda/Gda-6.0.metadata b/libgda/Gda-6.0.metadata
index a36441e..65a9598 100644
--- a/libgda/Gda-6.0.metadata
+++ b/libgda/Gda-6.0.metadata
@@ -8,45 +8,9 @@ utility_data_model_dump_data_to_xml.parent type="Xml.Node*"
utility_holder_load_attributes.node type="Xml.Node*"
DataModelImport.new_xml_node.node type="Xml.Node*"
ServerOperation.load_data_from_xml.node type="Xml.Node*"
-// type overrides for GIR not well detected
-// MetaStore.meta_changed has introspectable="0" property. Removing these metas
-//MetaStore.meta_changed.changes type="GLib.SList<Gda.MetaStoreChange>"
-// ServerProvider.statement_to_sql has introspectable="0" property. Removing these metas
-//ServerProvider.statement_to_sql.params_used type="GLib.List<Gda.Holder>"
-Set.groups_list type="GLib.List<Gda.SetGroup>"
-Set.nodes_list type="GLib.List<Gda.SetNode>"
-Set.sources_list type="GLib.List<Gda.SetSource>"
-Set.get_holder_value nullable=true
-TransactionStatus.events type="GLib.List<Gda.TransactionStatusEvent>"
-MetaContext.column_names array=true
-MetaContext.column_names array_length_field="size"
-MetaContext.column_values array=true
-MetaContext.column_values array_length_field="size"
-MetaDbObject.depend_list type="GLib.List<Gda.MetaDbObject>"
-MetaTable.columns type="GLib.List<Gda.MetaTableColumn>"
-MetaTable.reverse_fk_list type="GLib.List<Gda.MetaTableForeignKey>"
-MetaTable.fk_list type="GLib.List<Gda.MetaTableForeignKey>"
-SetGroup.nodes type="GLib.List<Gda.SetNode>"
-SetSource.nodes type="GLib.List<Gda.SetNode>"
-SqlRenderingContext.params_used type="GLib.List<Gda.Holder>"
-DataModel.i_get_value_at unowned=true
-DataModel.i_get_value_at nullable=true
-DataModel.get_typed_value_at unowned=true
-DataModel.get_typed_value_at nullable=true
-DataModelIter.get_value_at unowned=true
-DataModelIter.get_value_at nullable=true
-DataModelIter.get_value_at_e unowned=true
-DataModelIter.get_value_at_e nullable=true
-DataModelIter.get_value_for_field unowned=true
-DataModelIter.get_value_for_field nullable=true
-Holder.get_value nullable=true
-Row.get_value nullable=true
+
Numeric.get_string nullable=true
MetaStore.extract_v name="extract"
ServerOperation.set_value_at_path name="set_value_at"
ServerOperation.get_value_at_path name="get_value_at"
-ServerOperation.get_value_at_path nullable=true
-DataHandler.get_value_from_sql nullable=true
-DataHandler.get_value_from_sql type="GLib.Value?"
-DataHandler.get_value_from_str nullable=true
-DataHandler.get_sane_init_value nullable=true
+
diff --git a/libgda/gda-data-handler.c b/libgda/gda-data-handler.c
index 9fd4495..d38769c 100644
--- a/libgda/gda-data-handler.c
+++ b/libgda/gda-data-handler.c
@@ -150,7 +150,7 @@ gda_data_handler_get_str_from_value (GdaDataHandler *dh, const GValue *value)
/**
* gda_data_handler_get_value_from_sql:
* @dh: an object which implements the #GdaDataHandler interface
- * @sql: (allow-none): an SQL string, or %NULL
+ * @sql: (allow-none) (transfer none): an SQL string, or %NULL
* @type: a GType
*
* Creates a new GValue which represents the SQL value given as argument. This is
@@ -182,7 +182,7 @@ gda_data_handler_get_value_from_sql (GdaDataHandler *dh, const gchar *sql, GType
/**
* gda_data_handler_get_value_from_str:
* @dh: an object which implements the #GdaDataHandler interface
- * @str: (allow-none): a string or %NULL
+ * @str: (allow-none) (transfer none): a string or %NULL
* @type: a GType
*
* Creates a new GValue which represents the @str value given as argument. This is
@@ -227,7 +227,7 @@ gda_data_handler_get_value_from_str (GdaDataHandler *dh, const gchar *str, GType
* Creates a new GValue which holds a sane initial value to be used if no value is specifically
* provided. For example for a simple string, this would return a new value containing the "" string.
*
- * Returns: (transfer full): the new #GValue, or %NULL if no such value can be created.
+ * Returns: (allow-none) (transfer full): the new #GValue, or %NULL if no such value can be created.
*/
GValue *
gda_data_handler_get_sane_init_value (GdaDataHandler *dh, GType type)
diff --git a/libgda/gda-data-model-iter.c b/libgda/gda-data-model-iter.c
index 6ad4bca..ce5d670 100644
--- a/libgda/gda-data-model-iter.c
+++ b/libgda/gda-data-model-iter.c
@@ -1050,7 +1050,7 @@ gda_data_model_iter_get_holder_for_field (GdaDataModelIter *iter, gint col)
*
* Get the value stored at the column @col in @iter. The returned value must not be modified.
*
- * Returns: (transfer none): the #GValue, or %NULL if the value could not be fetched
+ * Returns: (allow-none) (transfer none): the #GValue, or %NULL if the value could not be fetched
*/
const GValue *
gda_data_model_iter_get_value_at (GdaDataModelIter *iter, gint col)
@@ -1079,7 +1079,7 @@ gda_data_model_iter_get_value_at (GdaDataModelIter *iter, gint col)
*
* Get the value stored at the column @col in @iter. The returned value must not be modified.
*
- * Returns: (transfer none): the #GValue, or %NULL if the value could not be fetched
+ * Returns: (allow-none) (transfer none): the #GValue, or %NULL if the value could not be fetched
*
* Since: 4.2.10
*/
@@ -1139,7 +1139,7 @@ gda_data_model_iter_set_value_at (GdaDataModelIter *iter, gint col, const GValue
*
* Get the value stored at the column @field_name in @iter
*
- * Returns: (transfer none): the #GValue, or %NULL
+ * Returns: (allow-none) (transfer none): the #GValue, or %NULL
*/
const GValue *
gda_data_model_iter_get_value_for_field (GdaDataModelIter *iter, const gchar *field_name)
diff --git a/libgda/gda-data-model.c b/libgda/gda-data-model.c
index 93e9ac3..fe4ea50 100644
--- a/libgda/gda-data-model.c
+++ b/libgda/gda-data-model.c
@@ -713,7 +713,7 @@ gda_data_model_get_value_at (GdaDataModel *model, gint col, gint row, GError **e
* Upon errors %NULL will be returned and @error will be assigned a
* #GError from the #GDA_DATA_MODEL_ERROR domain.
*
- * Returns: a #GValue containing the value stored in the given
+ * Returns: (allow-none) (transfer none): a #GValue containing the value stored in the given
* position, or %NULL on error (out-of-bound position, wrong data type, etc).
*/
const GValue *
diff --git a/libgda/gda-holder.c b/libgda/gda-holder.c
index 3ce50a1..ed25a6f 100644
--- a/libgda/gda-holder.c
+++ b/libgda/gda-holder.c
@@ -456,7 +456,7 @@ gda_holder_copy (GdaHolder *orig)
}
/**
- * gda_holder_new_inline: (skip)
+ * gda_holder_new_inline:
* @type: a valid GLib type
* @id: (allow-none): the id of the holder to create, or %NULL
* @...: value to set
diff --git a/libgda/gda-meta-store.c b/libgda/gda-meta-store.c
index 27a3979..ef4d349 100644
--- a/libgda/gda-meta-store.c
+++ b/libgda/gda-meta-store.c
@@ -4246,7 +4246,7 @@ gda_meta_store_set_attribute_value (GdaMetaStore *store, const gchar *att_name,
column NMTOKEN #IMPLIED
ref_column NMTOKEN #IMPLIED>
-<!ELEMENT unique (column*)>
+<!ELEMENT unique (column)>
<!ELEMENT view (definition)>
<!ATTLIST view
diff --git a/libgda/gda-row.c b/libgda/gda-row.c
index 3ab1477..8c23346 100644
--- a/libgda/gda-row.c
+++ b/libgda/gda-row.c
@@ -237,7 +237,7 @@ gda_row_new (gint count)
* This is a pointer to the internal array of values. Don't try to free
* or modify it (modifying is reserved to database provider's implementations).
*
- * Returns: a pointer to the #GValue in the position @num of @row.
+ * Returns: (allow-none) (transfer none): a pointer to the #GValue in the position @num of @row.
*/
GValue *
gda_row_get_value (GdaRow *row, gint num)
diff --git a/libgda/gda-set.c b/libgda/gda-set.c
index 01f2306..ca336d1 100644
--- a/libgda/gda-set.c
+++ b/libgda/gda-set.c
@@ -1294,7 +1294,7 @@ gda_set_set_holder_value (GdaSet *set, GError **error, const gchar *holder_id, .
*
* Get the value of the #GdaHolder which ID is @holder_id
*
- * Returns: (transfer none): the requested GValue, or %NULL (see gda_holder_get_value())
+ * Returns: (allow-none) (transfer none): the requested GValue, or %NULL (see gda_holder_get_value())
*/
const GValue *
gda_set_get_holder_value (GdaSet *set, const gchar *holder_id)
diff --git a/libgda/gda-statement-extra.h b/libgda/gda-statement-extra.h
index 0439c82..20329d9 100644
--- a/libgda/gda-statement-extra.h
+++ b/libgda/gda-statement-extra.h
@@ -86,7 +86,7 @@ typedef gchar *(*GdaSqlRenderingValue) (const GValue *value, GdaSqlRendering
* GdaSqlRenderingContext:
* @flags: Global rendering options
* @params: Parameters to be used while doing the rendering
- * @params_used: When rendering is complete, contains the ordered list of parameters which have been used
while doing the rendering
+ * @params_used: (element-type GdaHolder): When rendering is complete, contains the ordered list of
parameters which have been used while doing the rendering
* @provider: Pointer to the server provider to be used
* @cnc: Pointer to the connection to be used
* @render_value: function to render a #GValue
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]