Akonadi
core/session.cpp
32 // ### FIXME pipelining got broken by switching result emission in JobPrivate::handleResponse to delayed emission
33 // in order to work around exec() deadlocks. As a result of that Session knows to late about a finished job and still
54 mParent->connect(connection, &Connection::reconnected, mParent, &Session::reconnected, Qt::QueuedConnection);
104 qCWarning(AKONADICORE_LOG) << "Error when establishing connection with Akonadi server:" << hello.errorMessage();
110 qCDebug(AKONADICORE_LOG) << "Connected to" << hello.serverName() << ", using protocol version" << hello.protocolVersion();
189 qCWarning(AKONADICORE_LOG) << "Protocol version mismatch. Server version is older (" << protocolVersion << ") than ours (" << Protocol::version()
198 qCWarning(AKONADICORE_LOG) << "Protocol version mismatch. Server version is newer (" << protocolVersion << ") than ours (" << Protocol::version()
215 // ### careful, this method can be called from the QObject dtor of job (see jobDestroyed() below)
306 void SessionPrivate::itemRevisionChanged(Akonadi::Item::Id itemId, int oldRevision, int newRevision)
345 sessionId = QCoreApplication::instance()->applicationName().toUtf8() + '-' + QByteArray::number(QRandomGenerator::global()->generate());
357 QObject::connect(ServerManager::self(), &ServerManager::stateChanged, mParent, [this](ServerManager::State state) {
403 Q_GLOBAL_STATIC(QThreadStorage<QPointer<Session>>, instances) // NOLINT(readability-redundant-member-init)
407 Q_ASSERT_X(!sessionId.isEmpty(), "SessionPrivate::createDefaultSession", "You tried to create a default session with empty session id!");
void aboutToQuit()
bool disconnect(const QObject *sender, const char *signal, const QObject *receiver, const char *method)
void setErrorText(const QString &errorText)
void result(KJob *job)
void reconnected()
This signal is emitted whenever the session has been reconnected to the server (e....
singleShot
static ServerManager * self()
Returns the singleton instance of this class, for connecting to its signals.
Definition: servermanager.cpp:186
void stateChanged(Akonadi::ServerManager::State state)
Emitted whenever the server state changes.
QByteArray number(int n, int base)
void generate(const QStringList &source, QStringList &target)
bool kill(KillVerbosity verbosity=Quietly)
QMetaObject::Connection connect(const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type)
Q_GLOBAL_STATIC(Internal::StaticControl, s_instance) class ControlPrivate
Definition: control.cpp:28
void destroyed(QObject *obj)
@ NotRunning
Server is not running, could be no one started it yet or it failed to start.
Definition: servermanager.h:37
QString i18n(const char *text, const TYPE &arg...)
static Session * defaultSession()
Returns the default session for this thread.
Definition: core/session.cpp:422
QCoreApplication * instance()
void writeFinished(Akonadi::Job *job)
This signal is emitted if the job has finished all write operations, ie.
QueuedConnection
applicationName
void error(QWidget *parent, const QString &text, const QString &title, const KGuiItem &buttonOk, Options options=Notify)
bool isEmpty() const const
bool invokeMethod(QObject *obj, const char *member, Qt::ConnectionType type, QGenericReturnArgument ret, QGenericArgument val0, QGenericArgument val1, QGenericArgument val2, QGenericArgument val3, QGenericArgument val4, QGenericArgument val5, QGenericArgument val6, QGenericArgument val7, QGenericArgument val8, QGenericArgument val9)
Session(const QByteArray &sessionId=QByteArray(), QObject *parent=nullptr)
Creates a new session.
Definition: core/session.cpp:378
void emitResult()
KLEO_EXPORT std::unique_ptr< GpgME::DefaultAssuanTransaction > sendCommand(std::shared_ptr< GpgME::Context > &assuanContext, const std::string &command, GpgME::Error &err)
void setError(int errorCode)
QRandomGenerator * global()
Helper integration between Akonadi and Qt.
This file is part of the KDE documentation.
Documentation copyright © 1996-2023 The KDE developers.
Generated on Tue Feb 7 2023 03:58:07 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2023 The KDE developers.
Generated on Tue Feb 7 2023 03:58:07 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.