/*
 * This file is part of buteo-sync-plugin-caldav package
 *
 * Copyright (C) 2013 Jolla Ltd. and/or its subsidiary(-ies).
 *
 * Contributors: Mani Chandrasekar <maninc@gmail.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 PUT_H
#define PUT_H

#include "request_p.h"

#include <QObject>
#include <QNetworkReply>
#include <QSslError>
#include <QStringList>

class QNetworkAccessManager;
class Settings;

class Put : public Request
{
    Q_OBJECT

public:
    explicit Put(QNetworkAccessManager *manager, Settings *settings, QObject *parent = 0);

    void sendIcalData(const QString &uri, const QString &icalData,
                      const QString &eTag = QString());

    QString updatedETag(const QString &uri) const;

protected:
    virtual void handleReply(QNetworkReply *reply);

private:
    QSet<QString> mLocalUriList;
    QHash<QString,QString> mUpdatedETags;
};

#endif // PUT_H
