Remove FileLoader::get_callback().
This commit is contained in:
parent
d5d9dabe7d
commit
c1629cf597
@ -405,10 +405,6 @@ void FileDownloader::on_progress(Progress progress) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FileLoader::Callback *FileDownloader::get_callback() {
|
|
||||||
return static_cast<FileLoader::Callback *>(callback_.get());
|
|
||||||
}
|
|
||||||
|
|
||||||
Status FileDownloader::process_check_query(NetQueryPtr net_query) {
|
Status FileDownloader::process_check_query(NetQueryPtr net_query) {
|
||||||
has_hash_query_ = false;
|
has_hash_query_ = false;
|
||||||
TRY_STATUS(check_net_query(net_query));
|
TRY_STATUS(check_net_query(net_query));
|
||||||
|
@ -88,7 +88,6 @@ class FileDownloader final : public FileLoader {
|
|||||||
int64 streaming_offset) final TD_WARN_UNUSED_RESULT;
|
int64 streaming_offset) final TD_WARN_UNUSED_RESULT;
|
||||||
Result<size_t> process_part(Part part, NetQueryPtr net_query) final TD_WARN_UNUSED_RESULT;
|
Result<size_t> process_part(Part part, NetQueryPtr net_query) final TD_WARN_UNUSED_RESULT;
|
||||||
void on_progress(Progress progress) final;
|
void on_progress(Progress progress) final;
|
||||||
FileLoader::Callback *get_callback() final;
|
|
||||||
Status process_check_query(NetQueryPtr net_query) final;
|
Status process_check_query(NetQueryPtr net_query) final;
|
||||||
Result<CheckInfo> check_loop(int64 checked_prefix_size, int64 ready_prefix_size, bool is_ready) final;
|
Result<CheckInfo> check_loop(int64 checked_prefix_size, int64 ready_prefix_size, bool is_ready) final;
|
||||||
void add_hash_info(const std::vector<telegram_api::object_ptr<telegram_api::fileHash>> &hashes);
|
void add_hash_info(const std::vector<telegram_api::object_ptr<telegram_api::fileHash>> &hashes);
|
||||||
|
@ -83,7 +83,6 @@ class FileLoader : public FileLoaderActor {
|
|||||||
int64 size{0};
|
int64 size{0};
|
||||||
};
|
};
|
||||||
virtual void on_progress(Progress progress) = 0;
|
virtual void on_progress(Progress progress) = 0;
|
||||||
virtual Callback *get_callback() = 0;
|
|
||||||
virtual Result<PrefixInfo> on_update_local_location(const LocalFileLocation &location,
|
virtual Result<PrefixInfo> on_update_local_location(const LocalFileLocation &location,
|
||||||
int64 file_size) TD_WARN_UNUSED_RESULT {
|
int64 file_size) TD_WARN_UNUSED_RESULT {
|
||||||
return Status::Error("Unsupported");
|
return Status::Error("Unsupported");
|
||||||
|
@ -324,10 +324,6 @@ void FileUploader::on_progress(Progress progress) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FileLoader::Callback *FileUploader::get_callback() {
|
|
||||||
return static_cast<FileLoader::Callback *>(callback_.get());
|
|
||||||
}
|
|
||||||
|
|
||||||
void FileUploader::keep_fd_flag(bool keep_fd) {
|
void FileUploader::keep_fd_flag(bool keep_fd) {
|
||||||
keep_fd_ = keep_fd;
|
keep_fd_ = keep_fd;
|
||||||
try_release_fd();
|
try_release_fd();
|
||||||
|
@ -68,7 +68,6 @@ class FileUploader final : public FileLoader {
|
|||||||
int64 streaming_offset) final TD_WARN_UNUSED_RESULT;
|
int64 streaming_offset) final TD_WARN_UNUSED_RESULT;
|
||||||
Result<size_t> process_part(Part part, NetQueryPtr net_query) final TD_WARN_UNUSED_RESULT;
|
Result<size_t> process_part(Part part, NetQueryPtr net_query) final TD_WARN_UNUSED_RESULT;
|
||||||
void on_progress(Progress progress) final;
|
void on_progress(Progress progress) final;
|
||||||
FileLoader::Callback *get_callback() final;
|
|
||||||
Result<PrefixInfo> on_update_local_location(const LocalFileLocation &location,
|
Result<PrefixInfo> on_update_local_location(const LocalFileLocation &location,
|
||||||
int64 file_size) final TD_WARN_UNUSED_RESULT;
|
int64 file_size) final TD_WARN_UNUSED_RESULT;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user