WebSocket++
0.8.3-dev
C++ websocket client/server library
|
Error code category and codes used by all processor types. More...
Classes | |
class | processor_category |
Category for processor errors. More... | |
Functions | |
lib::error_category const & | get_processor_category () |
Get a reference to a static copy of the processor error category. | |
lib::error_code | make_error_code (error::processor_errors e) |
Create an error code with the given value and the processor category. | |
close::status::value | to_ws (lib::error_code ec) |
Converts a processor error_code into a websocket close code. More... | |
Error code category and codes used by all processor types.
|
inline |
Converts a processor error_code into a websocket close code.
Looks up the appropriate WebSocket close code that should be sent after an error of this sort occurred.
If the error is not in the processor category close::status::blank is returned.
If the error isn't normally associated with reasons to close a connection (such as errors intended to be used internally or delivered to client applications, ex: invalid arguments) then close::status::internal_endpoint_error is returned.