[Telepathy] Which ContactList interface methods are essential?
akulichalexander at gmail.com
Sat May 14 07:48:05 UTC 2016
On 10/05/16 20:34, Mateus Bellomo wrote:
> I would like to know what are the ... methods that I should implement.
Read the doc and implement methods which do what you need.
Most telepathy clients will not show contact list without info about
contact attributes, so you definitely have to implement
GetContactListAttributes(). All other methods needed to do what they
said to do.
Do you need to be able to remove a contact from the list? Implement
Want to add a contact? The method name is not too obvious, but it's
easy to figure it out from the specification - RequestSubscription().
And so on.
On Sat, May 14, 2016 at 12:26 PM, Daniel Pocock <daniel at pocock.pro> wrote:
> In all the other methods, you could include a log message to indicate
> that an unimplemented method has been called, beware of doing this if it
> overrides an implementation in a superclass though.
TelepathyQt uses conception of callback instead of virtual method.
This let us to implement an object (such as protocol, connection or
channel) interfaces right in the object class, instead of subclassing
tens of interfaces with just a few methods.
TelepathyQt interfaces automatically log unimplemented method calls.
E.g. if you run test-base-cm, you'll see follow line in the log:
QDEBUG : TestBaseCM::testProtocols() tp-qt 0.9.7 DEBUG:
"org.freedesktop.Telepathy.Error.NotImplemented": "Not implemented"
More information about the telepathy