#pragma once

#include <memory>
#include <vector>

#include "HttpClient.h"
#include "HttpServer.h"

class AbstractWebApp;

class NetworkManager
{
public:
    NetworkManager();

    ~NetworkManager();

    static std::unique_ptr<NetworkManager> Create();

    HttpClient* getHttpClient() const;

    void runHttpServer(AbstractWebApp* webApp);

private:
    std::unique_ptr<HttpServer> mHttpServer;
    std::unique_ptr<HttpClient> mHttpClient;
};

using NetworkManagerUPtr = std::unique_ptr<NetworkManager>;
