NS-3 based Named Data Networking (NDN) simulator
ndnSIM 2.3: NDN, CCN, CCNx, content centric networks
API Documentation
websocketpp::processor::error Namespace Reference

Error code category and codes used by all processor types. More...

Classes

class  processor_category
 Category for processor errors. More...
 

Enumerations

enum  processor_errors {
  general = 1, bad_request, protocol_violation, message_too_big,
  invalid_payload, invalid_arguments, invalid_opcode, control_too_big,
  invalid_rsv_bit, fragmented_control, invalid_continuation, masking_required,
  masking_forbidden, non_minimal_encoding, requires_64bit, invalid_utf8,
  not_implemented, invalid_http_method, invalid_http_version, invalid_http_status,
  missing_required_header, sha1_library, no_protocol_support, reserved_close_code,
  invalid_close_code, reason_requires_code, subprotocol_parse_error, extension_parse_error,
  extensions_disabled, short_key3
}
 

Functions

lib::error_category const & get_processor_category ()
 Get a reference to a static copy of the processor error category. More...
 
lib::error_code make_error_code (error::processor_errors e)
 Create an error code with the given value and the processor category. More...
 
close::status::value to_ws (lib::error_code ec)
 Converts a processor error_code into a websocket close code. More...
 

Detailed Description

Error code category and codes used by all processor types.

Enumeration Type Documentation

Enumerator
general 

Catch-all error for processor policy errors that don't fit in other categories.

bad_request 

Error was the result of improperly formatted user input.

protocol_violation 

Processor encountered a protocol violation in an incoming message.

message_too_big 

Processor encountered a message that was too large.

invalid_payload 

Processor encountered invalid payload data.

invalid_arguments 

The processor method was called with invalid arguments.

invalid_opcode 

Opcode was invalid for requested operation.

control_too_big 

Control frame too large.

invalid_rsv_bit 

Illegal use of reserved bit.

fragmented_control 

Fragmented control message.

invalid_continuation 

Continuation without message.

masking_required 

Clients may not send unmasked frames.

masking_forbidden 

Servers may not send masked frames.

non_minimal_encoding 

Payload length not minimally encoded.

requires_64bit 

Not supported on 32 bit systems.

invalid_utf8 

Invalid UTF-8 encoding.

not_implemented 

Operation required not implemented functionality.

invalid_http_method 

Invalid HTTP method.

invalid_http_version 

Invalid HTTP version.

invalid_http_status 

Invalid HTTP status.

missing_required_header 

Missing Required Header.

sha1_library 

Embedded SHA-1 library error.

no_protocol_support 

No support for this feature in this protocol version.

reserved_close_code 

Reserved close code used.

invalid_close_code 

Invalid close code used.

reason_requires_code 

Using a reason requires a close code.

subprotocol_parse_error 

Error parsing subprotocols.

extension_parse_error 

Error parsing extensions.

extensions_disabled 

Extension related operation was ignored because extensions are disabled.

short_key3 

Short Ke3 read.

Hybi00 requires a third key to be read from the 8 bytes after the handshake. Less than 8 bytes were read.

Definition at line 66 of file base.hpp.

Function Documentation

lib::error_category const& websocketpp::processor::error::get_processor_category ( )
inline

Get a reference to a static copy of the processor error category.

Definition at line 238 of file base.hpp.

Referenced by make_error_code(), and to_ws().

close::status::value websocketpp::processor::error::to_ws ( lib::error_code  ec)
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.

Definition at line 261 of file base.hpp.

References _WEBSOCKETPP_ERROR_CODE_ENUM_NS_START_, websocketpp::close::status::blank, control_too_big, fragmented_control, get_processor_category(), websocketpp::close::status::internal_endpoint_error, invalid_close_code, invalid_continuation, invalid_opcode, invalid_payload, websocketpp::close::status::invalid_payload, invalid_rsv_bit, invalid_utf8, masking_forbidden, masking_required, message_too_big, websocketpp::close::status::message_too_big, websocketpp::close::status::protocol_error, protocol_violation, and reserved_close_code.

Referenced by websocketpp::connection< config >::handle_read_frame().