2024-07-05 20:37:02 +01:00
|
|
|
#ifndef ERPC_CLIENT_HPP
|
|
|
|
#define ERPC_CLIENT_HPP
|
|
|
|
|
|
|
|
#include <string>
|
2024-07-08 21:15:55 +01:00
|
|
|
#include <vector>
|
2024-07-05 20:37:02 +01:00
|
|
|
#include <netinet/in.h>
|
|
|
|
|
|
|
|
namespace eRPC
|
|
|
|
{
|
|
|
|
class Client
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
Client(std::string host, int port);
|
|
|
|
~Client();
|
2024-07-08 21:15:55 +01:00
|
|
|
std::string call(std::string method, std::vector<std::string> params);
|
2024-07-05 20:37:02 +01:00
|
|
|
|
|
|
|
private:
|
|
|
|
int sockfd;
|
2024-07-08 21:15:55 +01:00
|
|
|
sockaddr_in serverAddress;
|
2024-07-05 20:37:02 +01:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif // ERPC_CLIENT_HPP
|