Commit c70758c7 authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Return new resource name

parent 831532a8
......@@ -45,9 +45,7 @@ Akonadi::Collection::Id ImportAddressbookJobInterfaceTestImpl::convertFolderPath
QString ImportAddressbookJobInterfaceTestImpl::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
{
mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
//TODO
return {};
return mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
}
void ImportAddressbookJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
......
......@@ -45,9 +45,7 @@ Akonadi::Collection::Id ImportAlarmJobInterfaceTestImpl::convertFolderPathToColl
QString ImportAlarmJobInterfaceTestImpl::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
{
mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
//TODO
return {};
return mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
}
void ImportAlarmJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
......
......@@ -45,9 +45,7 @@ Akonadi::Collection::Id ImportCalendarJobInterfaceTestImpl::convertFolderPathToC
QString ImportCalendarJobInterfaceTestImpl::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
{
mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
//TODO
return {};
return mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
}
void ImportCalendarJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
......
......@@ -52,7 +52,7 @@ QString LogCreatingResource::logPath() const
return mTmpLogFile->fileName();
}
void LogCreatingResource::logCreateResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
QString LogCreatingResource::logCreateResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
{
QTextStream stream(mTmpLogFile);
stream << resources << '\n';
......@@ -64,4 +64,5 @@ void LogCreatingResource::logCreateResource(const QString &resources, const QStr
}
stream << synchronizeTree << '\n';
qDebug() << "settings "<< settings;
return resources + QStringLiteral("new_resource1");
}
......@@ -30,7 +30,7 @@ public:
~LogCreatingResource();
void appendText(const QString &str);
Q_REQUIRED_RESULT QString logPath() const;
void logCreateResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree);
Q_REQUIRED_RESULT QString logCreateResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree);
void logSynchronizeResource(const QStringList &lst);
private:
QTemporaryFile *mTmpLogFile = nullptr;
......
......@@ -52,10 +52,7 @@ void ImportMailJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
QString ImportMailJobInterfaceTestImpl::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
{
mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
qDebug() << " QString ImportMailJobInterfaceTestImpl::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings)" << resources << " name " << name << " settings " << settings;
//TODO
return {};
return mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
}
void ImportMailJobInterfaceTestImpl::registerSpecialCollection(Akonadi::SpecialMailCollections::Type type, qint64 colId)
......
......@@ -46,10 +46,7 @@ Akonadi::Collection::Id ImportNotesJobInterfaceTestImpl::convertFolderPathToColl
QString ImportNotesJobInterfaceTestImpl::createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings, bool synchronizeTree)
{
mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
qDebug() << " QString createResource(const QString &resources, const QString &name, const QMap<QString, QVariant> &settings)" << resources << " name " << name << " settings " << settings;
//TODO
return {};
return mLogCreateResource->logCreateResource(resources, name, settings, synchronizeTree);
}
void ImportNotesJobInterfaceTestImpl::synchronizeResource(const QStringList &lst)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment