comparison Core/HttpServer/MongooseServer.cpp @ 911:306afd58a0b3 plugins

fix build
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 20 Jun 2014 13:45:22 +0200
parents ef71057d8b26
children dcb2469f00f4
comparison
equal deleted inserted replaced
910:28a52982196e 911:306afd58a0b3
66 66
67 67
68 namespace 68 namespace
69 { 69 {
70 // Anonymous namespace to avoid clashes between compilation modules 70 // Anonymous namespace to avoid clashes between compilation modules
71 class MongooseOutputStream : public HttpOutputStream 71 class MongooseOutputStream : public IHttpOutputStream
72 { 72 {
73 private: 73 private:
74 struct mg_connection* connection_; 74 struct mg_connection* connection_;
75 75
76 protected:
77 virtual void Send(bool isHeader, const void* buffer, size_t length)
78 {
79 if (length > 0)
80 {
81 mg_write(connection_, buffer, length);
82 }
83 }
84
85 public: 76 public:
86 MongooseOutputStream(struct mg_connection* connection) : connection_(connection) 77 MongooseOutputStream(struct mg_connection* connection) : connection_(connection)
87 { 78 {
79 }
80
81 virtual void Send(bool isHeader, const void* buffer, size_t length)
82 {
83 if (length > 0)
84 {
85 mg_write(connection_, buffer, length);
86 }
87 }
88
89 virtual void OnHttpStatusReceived(HttpStatus status)
90 {
91 // Ignore this
88 } 92 }
89 }; 93 };
90 94
91 95
92 enum PostDataStatus 96 enum PostDataStatus