c913091417b05af9bb24dcad35ec2a76ef6d7961
[anna.git] / example / timex / ArithmeticHTTPServer / Reactor.hpp
1 // ANNA - Anna is Not Nothingness Anymore                                                         //
2 //                                                                                                //
3 // (c) Copyright 2005-2015 Eduardo Ramos Testillano & Francisco Ruiz Rayo                         //
4 //                                                                                                //
5 // See project site at http://redmine.teslayout.com/projects/anna-suite                           //
6 // See accompanying file LICENSE or copy at http://www.teslayout.com/projects/public/anna.LICENSE //
7
8
9 #ifndef timex_ArithmeticHTTPServer_Reactor_hpp
10 #define timex_ArithmeticHTTPServer_Reactor_hpp
11
12 #include <anna/comm/Receiver.hpp>
13
14 #include <anna/http/Response.hpp>
15
16 #include "Request.hpp"
17 #include "Response.hpp"
18
19 namespace test {
20
21 namespace http4comm {
22
23 using namespace anna;
24
25 class Reactor : public comm::Receiver {
26 public:
27    Reactor () : comm::Receiver ("http4comm::Reactor") {;}
28
29    static const char* className () throw () { return "http4comm::Reactor"; }
30
31 private:
32    Request a_request;
33    Response a_response;
34    http::Response a_httpResponse;
35
36    void apply (comm::ClientSocket&, const comm::Message&) throw (RuntimeException);
37 };
38
39 }
40 }
41
42 #endif
43