make Nagle's algorithm configurable

This commit is contained in:
Xertis 2025-09-30 23:45:00 +03:00
parent e3da256c5d
commit b6ca7cf918
5 changed files with 50 additions and 0 deletions

View file

@ -76,6 +76,8 @@ namespace network {
virtual void connect(runnable callback) = 0;
virtual int recv(char* buffer, size_t length) = 0;
virtual int available() = 0;
virtual void setNoDelay(bool noDelay) = 0;
[[nodiscard]] virtual bool getNoDelay() const = 0;
[[nodiscard]] TransportType getTransportType() const noexcept override {
return TransportType::TCP;