22 lines
539 B
C++
22 lines
539 B
C++
#include "Service.h"
|
|
#include "TCPServerSocket.h"
|
|
#include "Exception.h"
|
|
|
|
namespace core {
|
|
|
|
Service::Service(TCPServerSocket &server) : server(server) {}
|
|
|
|
void Service::removeFromSessionList(Session *session) {
|
|
std::vector<Session *>::iterator cursor;
|
|
for(cursor = sessions.begin(); cursor < sessions.end(); ++cursor)
|
|
if(*cursor == session)
|
|
sessions.erase(cursor);
|
|
}
|
|
|
|
void Service::sessionErrorHandler(std::string errorString, Session *session) {
|
|
throw Exception(errorString);
|
|
}
|
|
|
|
}
|
|
|