class PropagateUploadFileNG : public PropagateUploadFileCommon
{
Q_OBJECT
-private:
- qint64 _sent = 0; /// amount of data (bytes) that was already sent
- uint _transferId = 0; /// transfer id (part of the url)
- int _currentChunk = 0; /// Id of the next chunk that will be sent
- qint64 _currentChunkSize = 0; /// current chunk size
- bool _removeJobError = false; /// If not null, there was an error removing the job
-
- // Map chunk number with its size from the PROPFIND on resume.
- // (Only used from slotPropfindIterate/slotPropfindFinished because the LsColJob use signals to report data.)
- struct ServerChunkInfo
- {
- qint64 size = 0LL;
- QString originalName;
- };
- QMap<qint64, ServerChunkInfo> _serverChunks;
-
- /**
- * Return the URL of a chunk.
- * If chunk == -1, returns the URL of the parent folder containing the chunks
- */
- QUrl chunkUrl(int chunk = -1);
public:
PropagateUploadFileNG(OwncloudPropagator *propagator, const SyncFileItemPtr &item)
void doStartUpload() override;
-private:
- void startNewUpload();
- void startNextChunk();
- void finishUpload();
-
public slots:
void abort(OCC::PropagateUploadFileNG::AbortType abortType) override;
void slotPutFinished();
void slotMoveJobFinished();
void slotUploadProgress(qint64, qint64);
+
+private:
+ // Map chunk number with its size from the PROPFIND on resume.
+ // (Only used from slotPropfindIterate/slotPropfindFinished because the LsColJob use signals to report data.)
+ struct ServerChunkInfo {
+ qint64 size = 0LL;
+ QString originalName;
+ };
+
+ /**
+ * Return the URL of a chunk.
+ * If chunk == -1, returns the URL of the parent folder containing the chunks
+ */
+ QUrl chunkUrl(int chunk = -1);
+
+ void startNewUpload();
+ void startNextChunk();
+ void finishUpload();
+
+ QMap<qint64, ServerChunkInfo> _serverChunks;
+
+ qint64 _sent = 0; /// amount of data (bytes) that was already sent
+ uint _transferId = 0; /// transfer id (part of the url)
+ int _currentChunk = 0; /// Id of the next chunk that will be sent
+ qint64 _currentChunkSize = 0; /// current chunk size
+ bool _removeJobError = false; /// If not null, there was an error removing the job
};
}