Review Request: Add API to clear logs
Dan Vratil
dan at progdan.cz
Mon Aug 27 20:58:34 UTC 2012
> On Aug. 27, 2012, 1:03 a.m., David Edmundson wrote:
> > TelepathyLoggerQt4/log-manager.cpp, line 91
> > <http://git.reviewboard.kde.org/r/106228/diff/1/?file=81369#file81369line91>
> >
> > don't do this.
> >
> > 1) Sync calls are bad
> >
> > 2) Tp has a special way of generating Dbus bindings, where you provide an XML file and it magically builds everything. This already exists in the TpLoggerQt. If you open (in your build folder) _gen/cli-logger.h you will find it actually has these calls.
> >
> > They should still be wrapped in the LogManager, just like you've done, but instead we should keep an instance of the auto generated LoggerInterface and use that. Also calls should be wrapped in Tp::PendingOperation
> >
> > so we get something like
> >
> > clearAccountHistory(account)
> > {
> > return Tp::PendingVoid(m_interface->ClearAccount(account->objectPath()), account);
> > }
> >
> >
> > For any other project this would be absolutely fine, but TpQt has their own special way, so we should follow that.
> >
> > I should have mentioned it in the bug, but I didn't think about it till now.
Stupid me...if I just checked the logger.cpp I could have saved few hours of fighting DBus.
I can see that there is a code in Tpl::Logger, but I have no idea how to get it to Tpl::LogManager...help please :)
- Dan
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/106228/#review18067
-----------------------------------------------------------
On Aug. 26, 2012, 11:10 p.m., Dan Vratil wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/106228/
> -----------------------------------------------------------
>
> (Updated Aug. 26, 2012, 11:10 p.m.)
>
>
> Review request for Telepathy and David Edmundson.
>
>
> Description
> -------
>
> Add three new methods to Tpl::LogManager to invoke telepathy-logger DBus methods for clearing logs.
>
>
> Diffs
> -----
>
> TelepathyLoggerQt4/log-manager.h c245965
> TelepathyLoggerQt4/log-manager.cpp e6acf40
>
> Diff: http://git.reviewboard.kde.org/r/106228/diff/
>
>
> Testing
> -------
>
> Works, be careful :)
>
>
> Thanks,
>
> Dan Vratil
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-telepathy/attachments/20120827/377eb2d1/attachment-0001.html>
More information about the KDE-Telepathy
mailing list