mirror of
https://github.com/Ladebeze66/ft_irc.git
synced 2025-12-16 05:58:09 +01:00
46 lines
1.4 KiB
C++
46 lines
1.4 KiB
C++
/* ************************************************************************** */
|
|
/* */
|
|
/* ::: :::::::: */
|
|
/* ClientManager.hpp :+: :+: :+: */
|
|
/* +:+ +:+ +:+ */
|
|
/* By: fgras-ca <fgras-ca@student.42.fr> +#+ +:+ +#+ */
|
|
/* +#+#+#+#+#+ +#+ */
|
|
/* Created: 2024/05/15 18:30:07 by fgras-ca #+# #+# */
|
|
/* Updated: 2024/05/16 16:26:03 by fgras-ca ### ########.fr */
|
|
/* */
|
|
/* ************************************************************************** */
|
|
|
|
#ifndef CLIENTMANAGER_HPP
|
|
#define CLIENTMANAGER_HPP
|
|
|
|
#include <map>
|
|
#include <vector>
|
|
#include "Client.hpp"
|
|
#include "Channel.hpp"
|
|
#include "Server.hpp"
|
|
#include <poll.h>
|
|
#include "CommandHandler.hpp"
|
|
#include "Utils.hpp"
|
|
#include <sys/socket.h>
|
|
#include <unistd.h>
|
|
#include <cstring>
|
|
#include <sstream>
|
|
#include <algorithm>
|
|
#include <fcntl.h>
|
|
|
|
class Server;
|
|
|
|
class ClientManager
|
|
{
|
|
public:
|
|
ClientManager(Server *server);
|
|
void acceptClient();
|
|
void handleClient(int client_fd);
|
|
void removeClient(int client_fd);
|
|
|
|
private:
|
|
Server *_server;
|
|
};
|
|
|
|
#endif
|