Thank you Ivan for pointing me to tracker-introspect.xml so If I'm not wrong that GPtrArray is NULL terminated and contains two char*. but if I do result[0] it is alwais NULL. This means for instance that the Audio service has no keywords.
Maybe I misunderstood the meaning of "keyword". for the Audio service, Audio:Title is a keyword, am I right? And tracker should automatically add keywords for watched files. If trakcer does not automatically add keywords like Audio:Title, this extension won't work, unless there is an API to extract from the tracker db the all tags belonging to a file (for Audio, Video, Images and Documents services). Bye! On Wed, Jul 16, 2008 at 2:32 PM, Ivan Frade <[EMAIL PROTECTED]> wrote: > Hi Yelo, > > El mié, 16-07-2008 a las 12:23 +0200, ext yelo_3 escribió: >> I'm really stuck with tracker api... Is there any documentation? > > At the moment, you can read the comments in the XML description of the > API: > > http://svn.gnome.org/svn/tracker/trunk/data/tracker-introspect.xml > > >> I have 2 problems that I hope someone will solve: >> 1) GPtrArray * tracker_keywords_get_list (TrackerClient *client, >> ServiceType service, GError **error); what does this function >> return? > > <!-- > gets a list of all unique keywords/tags that are in use by the > specified service irrespective of the uri or id of the entity > > Returns an array of string arrays in format [Keyword, KeywordCount] > --> > <method name="GetList"> > > >> 2) char ** tracker_keywords_get (TrackerClient *client, ServiceType >> service, const char *id, GError **error); I guess this function >> returns a NULL terminateed array of strings, which are the keywords >> that the file "id" has in the specified service. Unfortunately the >> first entry is always NULL. I've tested it with documents and with >> music files... What's wrong with this? > > It gives you the keywords (tags) for a file. Have you use "_set" > previously to set some keywords? > > > Regards, > > Ivan > > _______________________________________________ tracker-list mailing list tracker-list@gnome.org http://mail.gnome.org/mailman/listinfo/tracker-list