Files
boost_beast/include/boost/beast/websocket/error.hpp

59 lines
1.4 KiB
C++
Raw Normal View History

2017-07-20 08:01:46 -07:00
//
2017-07-24 09:42:36 -07:00
// Copyright (c) 2016-2017 Vinnie Falco (vinnie dot falco at gmail dot com)
2017-07-20 08:01:46 -07:00
//
// Distributed under the Boost Software License, Version 1.0. (See accompanying
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
//
2017-07-20 13:40:34 -07:00
// Official repository: https://github.com/boostorg/beast
//
2017-07-20 08:01:46 -07:00
2017-07-20 13:40:34 -07:00
#ifndef BOOST_BEAST_WEBSOCKET_ERROR_HPP
#define BOOST_BEAST_WEBSOCKET_ERROR_HPP
2017-07-20 08:01:46 -07:00
#include <boost/beast/websocket/detail/error.hpp>
2017-10-10 07:49:03 -07:00
#include <boost/beast/core/detail/config.hpp>
2017-07-20 13:40:34 -07:00
#include <boost/beast/core/error.hpp>
2017-07-20 08:01:46 -07:00
2017-07-20 13:40:34 -07:00
namespace boost {
2017-07-20 08:01:46 -07:00
namespace beast {
namespace websocket {
/// Error codes returned from @ref beast::websocket::stream operations.
2017-07-20 08:01:46 -07:00
enum class error
{
/// Both sides performed a WebSocket close
closed = 1,
2017-07-20 08:01:46 -07:00
/// WebSocket connection failed, protocol violation
failed,
/// Upgrade handshake failed
handshake_failed,
/// buffer overflow
buffer_overflow,
/// partial deflate block
partial_deflate_block
2017-07-20 08:01:46 -07:00
};
/// Error conditions corresponding to sets of error codes.
enum class condition
{
/** Handshake failed
This condition indicates that the WebSocket handshake failed. If
the corresponding HTTP response indicates the keep-alive behavior,
then the handshake may be reattempted.
*/
handshake_failed = 1,
};
2017-07-20 08:01:46 -07:00
} // websocket
} // beast
2017-07-20 13:40:34 -07:00
} // boost
2017-07-20 08:01:46 -07:00
2017-07-20 13:40:34 -07:00
#include <boost/beast/websocket/impl/error.ipp>
2017-07-20 08:01:46 -07:00
#endif