VWeb/Includes/EPollManager.h
Maurice Grönwoldt 5bb68a7d02 Split VWeb into smaller headers
We have no make install support... so we don't need to have everything as a single-header and lib file.
2023-09-16 16:29:03 +02:00

17 lines
364 B
C++

#pragma once
#include <sys/epoll.h>
namespace VWeb {
class EPollManager {
public:
EPollManager();
~EPollManager();
[[nodiscard]] bool Dispatch(int sock, uint32_t eventType = EPOLLIN) const;
[[nodiscard]] bool UpdateEvents(int sock, uint32_t eventType = EPOLLIN) const;
int Wait(int idx, epoll_event *events) const;
protected:
int m_EpollID{-1};
};
}