Eneboo - Documentación para desarrolladores
|
00001 /*************************************************************************** 00002 FLNetwork.h 00003 ------------------- 00004 begin : vie oct 9 2008 00005 copyright : (C) 2003-2008 by InfoSiAL, S.L. 00006 email : mail@infosial.com 00007 ***************************************************************************/ 00008 /*************************************************************************** 00009 * This program is free software; you can redistribute it and/or modify * 00010 * it under the terms of the GNU General Public License as published by * 00011 * the Free Software Foundation; version 2 of the License. * 00012 ***************************************************************************/ 00013 /*************************************************************************** 00014 Este programa es software libre. Puede redistribuirlo y/o modificarlo 00015 bajo los términos de la Licencia Pública General de GNU en su 00016 versión 2, publicada por la Free Software Foundation. 00017 ***************************************************************************/ 00018 00019 #ifndef FLNETWORK_H 00020 #define FLNETWORK_H 00021 00022 #include <qurloperator.h> 00023 00024 class FLNetwork : public QObject 00025 { 00026 00027 Q_OBJECT 00028 00029 public: 00030 00031 FLNetwork(const QString &url); 00032 00033 public slots: 00034 00035 void get(const QString &location); 00036 void put(const QString &data, const QString &location); 00037 void copy(const QString &fromLocation, const QString &toLocation); 00038 00039 private slots: 00040 00041 void slotNetworkStart(QNetworkOperation *); 00042 void slotNetworkFinished(QNetworkOperation *); 00043 void slotNetworkData(const QByteArray &, QNetworkOperation *); 00044 void slotNetworkProgress(int, int, QNetworkOperation *); 00045 00046 signals: 00047 00048 void finished(); 00049 void start(); 00050 void data(const QString &); 00051 void dataTransferProgress(int, int); 00052 00053 private: 00054 00055 QUrlOperator networkOp_; 00056 }; 00057 00058 #endif