SyncBackup.h
/*
* This file is part of buteo-syncfw package
*
* Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
*
* Contact: Sateesh Kavuri <sateesh.kavuri@nokia.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public License
* version 2.1 as published by the Free Software Foundation.
*
* This library is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
* 02110-1301 USA
*
*/
#ifndef SYNCBACKUP_H
#define SYNCBACKUP_H
#include "SyncBackupProxy.h"
#include "SyncBackupAdaptor.h"
namespace Buteo {
class SyncBackup : public SyncBackupProxy // Derived from QObject
{
Q_OBJECT
public:
SyncBackup();
~SyncBackup();
bool getBackUpRestoreState();
void sendReply (uchar aResult);
public slots:
// From backup framework ...
uchar backupStarts(const QDBusMessage &message);
uchar backupFinished(const QDBusMessage &message);
uchar restoreStarts(const QDBusMessage &message);
uchar restoreFinished(const QDBusMessage &message);
private:
bool iBackupRestore;
QDBusMessage *iReply;
SyncBackupAdaptor *iAdaptor;
// Reply to backup dbus framework that response will
// be delayed
void sendDelayReply(const QDBusMessage &message);
#ifdef SYNCFW_UNIT_TESTS
friend class SyncBackupTest;
#endif
};
}
#endif // SYNCBACKUP_H
Buteo::SyncBackupAdaptor
Adaptor class for interface com.nokia.backupclient.
Definition SyncBackupAdaptor.h:52
Buteo::SyncBackupProxy
Defines a D-Bus backup proxy for the backupclient.
Definition SyncBackupProxy.h:41
Buteo::SyncBackup::SyncBackup
SyncBackup()
Default Constructor.
Definition SyncBackup.cpp:35
Buteo::SyncBackup::backupFinished
uchar backupFinished(const QDBusMessage &message)
Definition SyncBackup.cpp:109
Buteo::SyncBackup::sendReply
void sendReply(uchar aResult)
Reply to backup framework, result of o/p.
Definition SyncBackup.cpp:80
Buteo::SyncBackup::~SyncBackup
~SyncBackup()
Destructor.
Definition SyncBackup.cpp:54
Buteo::SyncBackup::restoreStarts
uchar restoreStarts(const QDBusMessage &message)
Definition SyncBackup.cpp:119
Buteo::SyncBackup::getBackUpRestoreState
bool getBackUpRestoreState()
Requests the current state og backup/restore operation.
Definition SyncBackup.cpp:138
Buteo::SyncBackup::restoreFinished
uchar restoreFinished(const QDBusMessage &message)
Definition SyncBackup.cpp:128
Buteo::SyncBackup::backupStarts
uchar backupStarts(const QDBusMessage &message)
Called by backup framework when backup starts.
Definition SyncBackup.cpp:100