20#ifndef LIBREPCB_CORE_FILEDOWNLOAD_H
21#define LIBREPCB_CORE_FILEDOWNLOAD_H
26#include "../fileio/filepath.h"
77 const QByteArray& checksum) noexcept;
This class is used to download a file asynchronously in a separate thread.
Definition: filedownload.h:46
void prepareRequest() override
Definition: filedownload.cpp:72
void setZipExtractionDirectory(const FilePath &dir) noexcept
Set extraction directory of the ZIP file to download.
Definition: filedownload.cpp:63
FilePath mDestination
Definition: filedownload.h:123
void fileDownloaded(librepcb::FilePath filepath)
File successfully downloaded signal (emitted right before finished())
FileDownload(const FileDownload &other)=delete
FilePath mExtractZipToDir
Definition: filedownload.h:127
void setExpectedChecksum(QCryptographicHash::Algorithm algorithm, const QByteArray &checksum) noexcept
Set the expected checksum of the file to download.
Definition: filedownload.cpp:56
QScopedPointer< QSaveFile > mFile
Definition: filedownload.h:124
void fetchNewData(QIODevice &device) noexcept override
Definition: filedownload.cpp:165
QCryptographicHash::Algorithm mHashAlgorithm
Definition: filedownload.h:125
void finalizeRequest() override
Definition: filedownload.cpp:98
QByteArray mExpectedChecksum
Definition: filedownload.h:126
void emitSuccessfullyFinishedSignals(QString contentType) noexcept override
Definition: filedownload.cpp:156
~FileDownload() noexcept
Definition: filedownload.cpp:49
void zipFileExtracted(librepcb::FilePath directory)
ZIP file successfully extracted signal (emitted right before finished())
This class represents absolute, well-formatted paths to files or directories.
Definition: filepath.h:129
Base class for network requests which are processed in the network access manager.
Definition: networkrequestbase.h:55
Definition: occmodel.cpp:77