xale-db
1.0
minimal SQL engine, written in c++
Loading...
Searching...
No Matches
ISocket.h
Go to the documentation of this file.
1
#ifndef NET_I_SOCKET_H
2
#define NET_I_SOCKET_H
3
4
#include <string>
5
#include <vector>
6
#include <cstdint>
7
8
namespace
Xale::Net
9
{
10
class
ISocket
11
{
12
public
:
13
virtual
bool
connect
(
const
std::string& hostAddress,
int
port) = 0;
14
virtual
int
send
(
const
std::vector<uint8_t>* data,
size_t
size) = 0;
15
virtual
int
receive
(std::vector<uint8_t>* buffer,
size_t
size) = 0;
16
virtual
void
close
() = 0;
17
};
18
}
19
20
#endif
// NET_I_SOCKET_H
Xale::Net::ISocket
Definition
ISocket.h:11
Xale::Net::ISocket::send
virtual int send(const std::vector< uint8_t > *data, size_t size)=0
Xale::Net::ISocket::receive
virtual int receive(std::vector< uint8_t > *buffer, size_t size)=0
Xale::Net::ISocket::close
virtual void close()=0
Xale::Net::ISocket::connect
virtual bool connect(const std::string &hostAddress, int port)=0
Xale::Net
Definition
IPacket.h:8
include
Net
Socket
ISocket.h
Generated by
1.16.1