Files
thehub/libs/p2p/FillAddressDBAction.h
T

45 lines
1.3 KiB
C++
Raw Permalink Normal View History

2020-04-17 19:33:06 +02:00
/*
* This file is part of the Flowee project
2021-02-02 13:08:07 +01:00
* Copyright (C) 2020 Tom Zander <tom@flowee.org>
2020-04-17 19:33:06 +02:00
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program 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 General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
2024-01-22 19:32:15 +01:00
#ifndef FLOWEE_FILLADDRESSDBACTION_H
#define FLOWEE_FILLADDRESSDBACTION_H
2020-04-17 19:33:06 +02:00
#include "Action.h"
#include <boost/asio.hpp>
class FillAddressDBAction : public Action
{
public:
FillAddressDBAction(DownloadManager *parent);
protected:
void execute(const boost::system::error_code &error) override;
private:
2023-11-03 16:58:38 +01:00
void onAddressResolveComplete(const boost::system::error_code& error, boost::asio::ip::tcp::resolver::results_type iterator);
2020-04-17 19:33:06 +02:00
int64_t m_lastRequestStarted = 0;
2023-11-03 18:28:27 +01:00
int m_dnsLookupState = 0;
2020-04-17 19:33:06 +02:00
boost::asio::ip::tcp::resolver m_resolver;
const std::vector<std::string> m_seeders;
};
#endif