...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
Close status codes.
Defined in header <boost/beast/websocket/rfc6455.hpp>
enum close_code
Name |
Description |
---|---|
|
Normal closure; the connection successfully completed whatever purpose for which it was created. |
|
The endpoint is going away, either because of a server failure or because the browser is navigating away from the page that opened the connection. |
|
The endpoint is terminating the connection due to a protocol error. |
|
The connection is being terminated because the endpoint received data of a type it cannot accept (for example, a text-only endpoint received binary data). |
|
The endpoint is terminating the connection because a message was received that contained inconsistent data (e.g., non-UTF-8 data within a text message). |
|
The endpoint is terminating the connection because it received a message that violates its policy. This is a generic status code, used when codes 1003 and 1009 are not suitable. |
|
The endpoint is terminating the connection because a data frame was received that is too large. |
|
The client is terminating the connection because it expected the server to negotiate one or more extension, but the server didn't. |
|
The server is terminating the connection because it encountered an unexpected condition that prevented it from fulfilling the request. |
|
The server is terminating the connection because it is restarting. |
|
The server is terminating the connection due to a temporary condition, e.g. it is overloaded and is casting off some of its clients. |
|
Used internally to mean "no error". This code is reserved and may not be sent. |
|
Reserved for future use by the WebSocket standard. This code is reserved and may not be sent. |
|
No status code was provided even though one was expected. This code is reserved and may not be sent. |
|
Connection was closed without receiving a close frame. This code is reserved and may not be sent. |
|
Reserved for future use by the WebSocket standard. This code is reserved and may not be sent. |
|
Reserved for future use by the WebSocket standard. This code is reserved and may not be sent. |
These codes accompany close frames.