Add toJson method for the protocol.
Summary:
To be able to send json as debug protocol, so we can better search and
parse this on akonadiconsole.
Test Plan: build
Reviewers: dvratil
Reviewed By: dvratil
Subscribers: anthonyfieroni, KDE PIM
Tags: KDE PIM
Differential Revision: https://phabricator.kde.org/D12736