summaryrefslogtreecommitdiffstats
path: root/Socket.h
diff options
context:
space:
mode:
authorMalf Furious <m@lfurio.us>2016-04-13 21:05:14 -0400
committerMalf Furious <m@lfurio.us>2016-04-13 21:05:14 -0400
commit490d36e65ac24e34e3021c2a0947384aee138c88 (patch)
tree418a229fa60708d7796bc61f90794626aefed9d5 /Socket.h
downloadcompass-490d36e65ac24e34e3021c2a0947384aee138c88.tar.gz
compass-490d36e65ac24e34e3021c2a0947384aee138c88.zip
Root commit for new Compass repository
This is the Alpha version of ComPASS, originally developed sometime in 2014.
Diffstat (limited to 'Socket.h')
-rw-r--r--Socket.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/Socket.h b/Socket.h
new file mode 100644
index 0000000..86b6478
--- /dev/null
+++ b/Socket.h
@@ -0,0 +1,29 @@
+#ifndef SOCKET_H
+#define SOCKET_H
+
+#include <string>
+#include <cstring>
+
+#ifdef WIN32
+#else
+#include <sys/socket.h>
+#include <netdb.h>
+#endif // WIN32
+
+class Socket {
+public:
+ Socket();
+ virtual ~Socket();
+
+ void conn(std::string host, std::string port);
+ void sendline(std::string line);
+ std::string readline();
+ void clo();
+
+private:
+ /*int sockid;
+ addrinfo hostInfo;
+ addrinfo* hostInfoList;*/
+};
+
+#endif // SOCKET_H