[Kde-pim] Setting and using GIDs

Christian Mollekopf chrigi_1 at fastmail.fm
Thu Mar 20 16:40:40 GMT 2014


On Thursday 20 March 2014 16.01:38 David Jarvie wrote:
> On Wednesday 19 Mar 2014 17:14:55 Daniel Vrátil wrote:
> > On Wednesday 19 of March 2014 16:57:37 David Jarvie wrote:
> > > On Wednesday 19 Mar 2014 15:21:32 Daniel Vrátil wrote:
> > > > Christian has added GID for exactly this purpose in KDE 4.12. In case
> > > > of
> > > > events GID == RID (because both GID and RID are iCal UIDs), but in 
> > > > emails
> > > > for example GID == Message-Id and RID == IMAP UID.
> > > 
> > > Yes, that would do the job. Are GIDs fully implemented yet?
> > 
> > Yes, they are. Maybe they are just not documented that much.
> > 
> > > I can't find for example how to fetch items by GID (ItemFetchJob doesn't
> > 
> > seem to have any GID options),
> > 
> > Just use Item::setGid() to set the GID and pass the item to ItemFetchJob.
> > Note that if you want the fetched items to have GID set too, you have to
> > explicitly enable that in ItemFetchScope.
> > 
> > > and it doesn't look like many resources set GIDs yet.
> > 
> > GID is automatically extracted by Serializer when the item is being pushed
> > to Akonadi for the first time. At least KMime, KCalCore and Adressee
> > serializers have this implemented (didn't check others), see
> > GidExtractorInterface.  No support for GIDs in Resources is needed.
> 
> This sounds great, but I'm having trouble finding the code which sets GIDs
> for anything except Addressees. That seems to be the only Serializer which
> implements GidExtractorInterface, and I can't find any other
> GidExtractorInterface class. How are GIDs set for iCal, for example? I need
> to implement GIDs for the KAlarm resources.

QString SerializerPluginKCalCore::extractGid( const Item &item ) const

(not kcalcore, not kcal)

It's implemented in kdepim-runtime/plugins/*

Cheers,
Christian
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/



More information about the kde-pim mailing list