-
Notifications
You must be signed in to change notification settings - Fork 0
/
netutil.hpp
27 lines (24 loc) · 909 Bytes
/
netutil.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//Copyright © 2023 Charles Kerr. All rights reserved.
#ifndef netutil_hpp
#define netutil_hpp
#include <cstdint>
#include <string>
#include <cstring>
#include "sock.hpp" // We include this, so users can just include one hpp file.
namespace util {
namespace net {
//=================================================================================
// Intialize the network
// For windows, this is initialize winsock2.
// For everythig else, nothing
auto initialize() ->void ;
//=================================================================================
// shutdown the network
// For windows, this is initialize winsock2.
// For everythig else, nothing
auto shutdown() ->void ;
// Get the text for error numbers
auto errormsg(int error) -> std::string;
}
}
#endif /* netutil_hpp */