jsocketpp 1.0
A cross-platform C++20 socket library.
Loading...
Searching...
No Matches
SocketTimeoutException.hpp
Go to the documentation of this file.
1
5
6#pragma once
7
8#include "common.hpp"
9#include "SocketException.hpp"
10
11namespace jsocketpp
12{
13
39{
40 public:
46 explicit SocketTimeoutException(const int errorCode = JSOCKETPP_TIMEOUT_CODE, std::string message = "")
47 : SocketException(errorCode, message.empty() ? SocketErrorMessage(errorCode) : std::move(message))
48 {
49 }
50};
51
52} // namespace jsocketpp
Exception class for socket-related errors in jsocketpp.
SocketTimeoutException(const int errorCode=JSOCKETPP_TIMEOUT_CODE, std::string message="")
Construct a new SocketTimeoutException with the specified or default timeout code and message.
Definition SocketTimeoutException.hpp:46
Common platform and utility includes for jsocketpp.
SocketException(const std::string &message="SocketException")
Constructs a SocketException with a custom error message and no associated error code.
Definition SocketException.hpp:77
A C++ socket library providing Java-style networking interfaces.
Definition BufferView.hpp:16
std::string SocketErrorMessage(int error, bool gaiStrerror=false)
Convert a socket-related error code to a human-readable message.
Definition common.cpp:5