[libgda] GIR and VAPI updates
- From: Daniel Espinosa Ortiz <despinosa src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgda] GIR and VAPI updates
- Date: Fri, 9 Mar 2012 17:46:34 +0000 (UTC)
commit 11b83bb0301598594dbc42acc14b49bbec93bc71
Author: Daniel Espinosa <despinosa src gnome org>
Date: Fri Mar 2 18:48:50 2012 -0600
GIR and VAPI updates
libgda/Gda-5.0.gir | 58 +++++++++++++++++++++++++++++++++++++++--------
libgda/libgda-5.0.vapi | 5 ++++
2 files changed, 53 insertions(+), 10 deletions(-)
---
diff --git a/libgda/Gda-5.0.gir b/libgda/Gda-5.0.gir
index 19fde7d..fbd3a6b 100644
--- a/libgda/Gda-5.0.gir
+++ b/libgda/Gda-5.0.gir
@@ -5232,6 +5232,29 @@ Upon errors -1 will be returned and @error will be assigned a
<type name="DataModelArray" c:type="GdaDataModelArray*"/>
</return-value>
</method>
+ <method name="array_copy_model_ext"
+ c:identifier="gda_data_model_array_copy_model_ext"
+ version="5.2.0"
+ throws="1">
+ <doc xml:whitespace="preserve">Like gda_data_model_array_copy_model(), makes a copy of @src, but copies only some
+columns.</doc>
+ <return-value transfer-ownership="full">
+ <doc xml:whitespace="preserve">a new data model, or %NULL if an error occurred</doc>
+ <type name="DataModelArray" c:type="GdaDataModelArray*"/>
+ </return-value>
+ <parameters>
+ <parameter name="ncols" transfer-ownership="none">
+ <doc xml:whitespace="preserve">size of @cols</doc>
+ <type name="gint" c:type="gint"/>
+ </parameter>
+ <parameter name="cols" transfer-ownership="none">
+ <doc xml:whitespace="preserve">array of @src's columns to copy into the new array, not %NULL</doc>
+ <array length="0" zero-terminated="0" c:type="gint*">
+ <type name="gint" c:type="gint"/>
+ </array>
+ </parameter>
+ </parameters>
+ </method>
<method name="create_iter" c:identifier="gda_data_model_create_iter">
<doc xml:whitespace="preserve">Creates a new iterator object #GdaDataModelIter object which can be used to iterate through
rows in @model. The new #GdaDataModelIter does not hold any reference to @model (ie. if @model
@@ -5327,12 +5350,12 @@ Specifically, the parameters in the @options list can be:
<itemizedlist>
<listitem><para>"SEPARATOR": a string value of which the first character is used as a separator in case of CSV export
</para></listitem>
-<listitem><para>"QUOTE": a string value of which the first character is used as a quote character in case of CSV export
-</para></listitem>
+<listitem><para>"QUOTE": a string value of which the first character is used as a quote character in case of CSV export. The
+default if not specified is the double quote character</para></listitem>
<listitem><para>"FIELD_QUOTE": a boolean value which can be set to FALSE if no quote around the individual fields
is requeted, in case of CSV export</para></listitem>
+<listitem><para>"NAMES_ON_FIRST_LINE": a boolean value which, if set to %TRUE and in case of a CSV export, will add a first line with the name each exported field (note that "FIELDS_NAME" is also accepted as a synonym)</para></listitem>
<listitem><para>"NAME": a string value used to name the exported data if the export format is XML</para></listitem>
-<listitem><para>"FIELDS_NAME": a boolean value which, if set to %TRUE and in case of a CSV export, will add a first line with the name each exported field</para></listitem>
<listitem><para>"OVERWRITE": a boolean value which tells if the file must be over-written if it already exists.</para></listitem>
<listitem><para>"NULL_AS_EMPTY": a boolean value which, if set to %TRUE and in case of a CSV export, will render and NULL value as the empty string (instead of the 'NULL' string)</para></listitem>
<listitem><para>"INVALID_AS_NULL": a boolean value which, if set to %TRUE, considers any invalid data (for example for the date related values) as NULL</para></listitem>
@@ -7002,8 +7025,8 @@ The options are the following ones:
<itemizedlist>
<listitem><para>ENCODING (string): specifies the encoding of the data in the file</para></listitem>
<listitem><para>SEPARATOR (string): specifies the CSV separator (comma as default)</para></listitem>
-<listitem><para>QUOTE (string): specifies the character used to as quote park (double quote as default)</para></listitem>
-<listitem><para>TITLE_AS_FIRST_LINE (boolean): consider that the first line of the file contains columns' titles</para></listitem>
+<listitem><para>QUOTE (string): specifies the character used as quote (double quote as default)</para></listitem>
+<listitem><para>NAMES_ON_FIRST_LINE (boolean): consider that the first line of the file contains columns' titles (note that the TITLE_AS_FIRST_LINE option is also accepted as a synonym)</para></listitem>
<listitem><para>G_TYPE_&lt;column number&gt; (GType): specifies the type of value expected in column &lt;column number&gt;</para></listitem>
</itemizedlist>
</para></listitem>
@@ -9940,14 +9963,12 @@ the memory it uses will be freed using the @destroy function when no longer need
then the string will not be freed at all).
Attributes can have any name, but Libgda proposes some default names,
-see <link linkend="libgda-40-Attributes-manager.synopsis">this section</link>.
+see <link linkend="libgda-5.0-Attributes-manager.synopsis">this section</link>.
For example one would use it as:
-<code>
-gda_holder_set_attribute (holder, g_strdup (my_attribute), g_free, my_value);
-gda_holder_set_attribute (holder, GDA_ATTRIBUTE_NAME, NULL, my_value);
-</code>
+<code>gda_holder_set_attribute (holder, g_strdup (my_attribute), my_value, g_free);</code>
+<code>gda_holder_set_attribute (holder, GDA_ATTRIBUTE_NAME, my_value, NULL);</code>
If there is already an attribute named @attribute set, then its value is replaced with the new value (@value is
copied), except if @value is %NULL, in which case the attribute is removed.</doc>
@@ -10208,6 +10229,14 @@ take care of the 'old' static GValue.</doc>
<property name="source-model" writable="1" transfer-ownership="none">
<type name="DataModel"/>
</property>
+ <property name="validate-changes"
+ version="5.2.0"
+ writable="1"
+ transfer-ownership="none">
+ <doc xml:whitespace="preserve">Defines if the "validate-change" signal gets emitted when
+the holder's value changes.</doc>
+ <type name="gboolean"/>
+ </property>
<field name="object">
<type name="GObject.Object" c:type="GObject"/>
</field>
@@ -17303,6 +17332,15 @@ the source by the new model</doc>
<property name="name" writable="1" transfer-ownership="none">
<type name="utf8"/>
</property>
+ <property name="validate-changes"
+ version="5.2.0"
+ writable="1"
+ transfer-ownership="none">
+ <doc xml:whitespace="preserve">Defines if the "validate-set" signal gets emitted when
+any holder in the data set changes. This property also affects the
+GdaHolder:validate-changes property.</doc>
+ <type name="gboolean"/>
+ </property>
<field name="object">
<type name="GObject.Object" c:type="GObject"/>
</field>
diff --git a/libgda/libgda-5.0.vapi b/libgda/libgda-5.0.vapi
index ed58303..f4ef6c5 100644
--- a/libgda/libgda-5.0.vapi
+++ b/libgda/libgda-5.0.vapi
@@ -580,6 +580,8 @@ namespace Gda {
public int source_column { get; set; }
[NoAccessorMethod]
public Gda.DataModel source_model { owned get; set; }
+ [NoAccessorMethod]
+ public bool validate_changes { get; set; }
public signal void attribute_changed (string att_name, GLib.Value att_value);
public virtual signal void changed ();
public virtual signal void source_changed ();
@@ -871,6 +873,8 @@ namespace Gda {
public string id { owned get; set; }
[NoAccessorMethod]
public string name { owned get; set; }
+ [NoAccessorMethod]
+ public bool validate_changes { get; set; }
public virtual signal void holder_attr_changed (Gda.Holder holder, string attr_name, GLib.Value attr_value);
public virtual signal void holder_changed (Gda.Holder holder);
public virtual signal void holder_type_set (Gda.Holder holder);
@@ -1214,6 +1218,7 @@ namespace Gda {
[CCode (vfunc_name = "i_append_row")]
public abstract int append_row () throws GLib.Error;
public Gda.DataModelArray array_copy_model () throws GLib.Error;
+ public Gda.DataModelArray array_copy_model_ext ([CCode (array_length_cname = "ncols", array_length_pos = 0.5)] int[] cols) throws GLib.Error;
[CCode (vfunc_name = "i_create_iter")]
public abstract Gda.DataModelIter create_iter ();
[CCode (vfunc_name = "i_describe_column")]
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]