Re: [Vala] libgdata or is it GData



On Sat, Jul 23, 2011 at 1:04 PM, Luca Bruno <lethalman88 gmail com> wrote:
First rule is to paste the errors, we can't help otherwise :)


Sure, thank you.  I get the following error running the code snippet I
found as is.

gdata_experiments.vala:26.24-26.75: error: 1 missing arguments for
`GData.DocumentsFeed GData.DocumentsService.query_documents
(GData.DocumentsQuery query, GLib.Cancellable cancellable,
GData.QueryProgressCallback progress_callback, void*
progress_user_data)'
            var feed = this.gdocs.query_documents (query, cancel, () => {});

I looked at valadoc api documentation and it indicates an additional
parameter of type void* (not sure what this is exactly - gpointer
according to the header file), so I add a null as the last parameter
and then I get the following error.

gdata_experiments.c:134:3: error: too many arguments to function
‘gdata_documents_service_query_documents’
/usr/include/libgdata/gdata/services/documents/gdata-documents-service.h:84:21:
note: declared here


//////////////////
copied from gdata-documents-service.h:
GDataDocumentsFeed *gdata_documents_service_query_documents
(GDataDocumentsService *self, GDataDocumentsQuery *query, GCancellable
*cancellable,

GDataQueryProgressCallback progress_callback, gpointer
progress_user_data,
                                                             GError
**error) G_GNUC_WARN_UNUSED_RESULT G_GNUC_MALLOC;

//////////////////
The vala code - original:
var feed = this.gdocs.query_documents (query, cancel, () => {});

//////////////////
The c code - generated:
_tmp2_ = gdata_documents_service_query_documents
(self->priv->gdocs,query, cancel,
__lambda1__gdata_query_progress_callback ,self, NULL,&_inner_error_);
                _tmp3_ = _g_object_ref0 (_tmp2_);
                feed = _tmp3_;


$ pkg-config --modversion libgdata
0.8.0
$ valac --version
Vala 0.13.1

-- 
Regards,
-Brian



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