26 lines
640 B
C++
26 lines
640 B
C++
//////////////////////////////////
|
|
// Created by Sam Svensson 2013 //
|
|
//////////////////////////////////
|
|
|
|
#ifndef NETWORK_DEPENDENCIES_I_CONNECTION_H
|
|
#define NETWORK_DEPENDENCIES_I_CONNECTION_H
|
|
|
|
namespace Oyster
|
|
{
|
|
namespace Network
|
|
{
|
|
class IConnection
|
|
{
|
|
|
|
public:
|
|
virtual void Disconnect() = 0;
|
|
virtual bool Send( const unsigned char message[] ) = 0;
|
|
virtual int Recieve(unsigned char message[]) = 0;
|
|
virtual bool InitiateServer( unsigned short port ) { return false; };
|
|
virtual int Listen() { return -1; };
|
|
virtual bool Connect( unsigned short port, const char serverName[] ) { return false; };
|
|
};
|
|
}
|
|
}
|
|
|
|
#endif |