Danbias/Code/Network/OysterNetworkServer/IServer.h

44 lines
749 B
C
Raw Normal View History

#ifndef OYSTER_NETWORK_SERVER_I_SERVER_H
#define OYSTER_NETWORK_SERVER_I_SERVER_H
/////////////////////////////////////
// Created by Pontus Fransson 2013 //
/////////////////////////////////////
2013-12-08 23:56:17 +01:00
#include "IClient.h"
2013-12-08 23:56:17 +01:00
namespace Oyster
{
namespace Network
{
2013-12-08 23:56:17 +01:00
namespace Server
{
class IServer
{
public:
struct INIT_DESC
{
unsigned short port; //Port the server should be accepting clients on.
void (*proc)(IClient*);
};
IServer();
virtual ~IServer();
virtual bool Init(INIT_DESC& initDesc);
virtual bool Start();
virtual bool Stop();
virtual bool Shutdown();
virtual bool IsStarted() const;
private:
struct PrivateData;
PrivateData* privateData;
};
}
}
}
#endif