2009-01-28 00:10:58 +00:00
|
|
|
// Cyphesis Online RPG Server and AI Engine
|
|
|
|
|
// Copyright (C) 2009 Alistair Riddoch
|
|
|
|
|
//
|
|
|
|
|
// This program is free software; you can redistribute it and/or modify
|
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
|
// the Free Software Foundation; either version 2 of the License, or
|
|
|
|
|
// (at your option) any later version.
|
|
|
|
|
//
|
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
// GNU General Public License for more details.
|
|
|
|
|
//
|
|
|
|
|
// You should have received a copy of the GNU General Public License
|
|
|
|
|
// along with this program; if not, write to the Free Software Foundation,
|
|
|
|
|
// Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
|
|
|
|
|
|
|
|
// $Id$
|
|
|
|
|
|
2009-03-22 20:07:36 +00:00
|
|
|
#ifndef SERVER_COMM_CLIENT_FACTORY_H
|
|
|
|
|
#define SERVER_COMM_CLIENT_FACTORY_H
|
|
|
|
|
|
2012-03-05 00:12:17 +00:00
|
|
|
#include "CommClientKit.h"
|
2009-01-28 00:10:58 +00:00
|
|
|
|
2011-10-30 01:04:36 +02:00
|
|
|
class ServerRouting;
|
|
|
|
|
|
2009-08-24 02:38:09 +01:00
|
|
|
/// \brief Concrete factory for createing CommClient objects
|
2012-07-31 23:32:22 +01:00
|
|
|
template <class SocketT, class ConnectionT>
|
2009-01-28 00:10:58 +00:00
|
|
|
class CommClientFactory : public CommClientKit {
|
2011-10-30 01:04:36 +02:00
|
|
|
protected:
|
|
|
|
|
ServerRouting & m_server;
|
2009-01-28 00:10:58 +00:00
|
|
|
public:
|
2011-10-30 01:04:36 +02:00
|
|
|
explicit CommClientFactory(ServerRouting & s) : m_server(s) { }
|
|
|
|
|
|
2009-01-28 00:10:58 +00:00
|
|
|
virtual int newCommClient(CommServer &, int, const std::string &);
|
|
|
|
|
};
|
2009-01-29 16:26:25 +00:00
|
|
|
|
2009-03-22 20:07:36 +00:00
|
|
|
#endif // SERVER_COMM_CLIENT_FACTORY_H
|