Class that should be implemented to handle incoming messages or disconnections. More...
#include <ana.hpp>

Public Member Functions | |
| virtual | ~listener_handler () |
| virtual void | handle_receive (error_code, net_id, read_buffer)=0 |
| Handle an incoming message event. | |
| virtual void | handle_disconnect (error_code, net_id)=0 |
| Handle a disconnect event. | |
Class that should be implemented to handle incoming messages or disconnections.
Definition at line 120 of file ana.hpp.
| virtual ana::listener_handler::~listener_handler | ( | ) | [inline, virtual] |
| virtual void ana::listener_handler::handle_disconnect | ( | error_code | , | |
| net_id | ||||
| ) | [pure virtual] |
Handle a disconnect event.
| error_code | : Error code of the disconnecting client, it could shed some light into why it got disconnected. | |
| net_id | : ID of the client that gets disconnected. |
Implemented in ana_receive_handler, and ana_multiple_receive_handler.
Referenced by asio_listener::disconnect().

| virtual void ana::listener_handler::handle_receive | ( | error_code | , | |
| net_id | , | |||
| read_buffer | ||||
| ) | [pure virtual] |
Handle an incoming message event.
| error_code | : Error code of the client sending the message, if it evaluates to false, then no error occurred. | |
| net_id | : ID of the client that sends the message. | |
| shared_buffer | : The buffer from the incoming message. |
Implemented in ana_receive_handler, and ana_multiple_receive_handler.
Referenced by asio_listener::handle_body(), asio_listener::handle_header(), asio_listener::handle_partial_body(), asio_listener::handle_raw_buffer(), and asio_listener::handle_timeout().

| Generated by doxygen 1.7.1 on Fri May 25 2012 01:17:58 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |