28#ifndef WEBSOCKETPP_TRANSPORT_IOSTREAM_BASE_HPP
29#define WEBSOCKETPP_TRANSPORT_IOSTREAM_BASE_HPP
47typedef lib::function<lib::error_code(
connection_hdl,
char const *,
size_t)>
56typedef lib::function<lib::error_code(
connection_hdl, std::vector<transport::buffer>
const
90 return "websocketpp.transport.iostream";
96 return "Generic iostream transport policy error";
98 return "async_read_at_least call requested more bytes than buffer can store";
100 return "Async read already in progress";
102 return "An output stream to be set before async_write can be used";
104 return "A stream operation returned ios::bad";
119 return lib::error_code(
static_cast<int>(e),
get_category());
127template<>
struct is_error_code_enum<
websocketpp::transport::iostream::error::value>
iostream transport error category
char const * name() const _WEBSOCKETPP_NOEXCEPT_TOKEN_
std::string message(int value) const
#define _WEBSOCKETPP_NOEXCEPT_TOKEN_
@ invalid_num_bytes
async_read_at_least call requested more bytes than buffer can store
@ double_read
async_read called while another async_read was in progress
lib::error_code make_error_code(error::value e)
Get an error code with the given value and the iostream transport category.
lib::error_category const & get_category()
Get a reference to a static copy of the iostream transport error category.
lib::function< lib::error_code(connection_hdl, std::vector< transport::buffer > const &bufs)> vector_write_handler
lib::function< lib::error_code(connection_hdl)> shutdown_handler
lib::function< lib::error_code(connection_hdl, char const *, size_t)> write_handler
The type and signature of the callback used by iostream transport to write.
Namespace for the WebSocket++ project.
lib::weak_ptr< void > connection_hdl
A handle to uniquely identify a connection.
#define _WEBSOCKETPP_ERROR_CODE_ENUM_NS_END_
#define _WEBSOCKETPP_ERROR_CODE_ENUM_NS_START_