Student project by David Berlin and Boris Dogadov made for the Embedded Systems Workshop course given in Tel-Aviv University on 2010 by Sivan Toledo. Visit the project website for more details: http://davidberlin.co.il/sadna/ .
Dependencies: EthernetNetIf NTPClient_NetServices mbed HTTPServer HTTPClient CyaSSL
HttpHandlerUsbBrowser.h@0:3e7d6f496a67, 2011-04-17 (annotated)
- Committer:
- sivan_toledo
- Date:
- Sun Apr 17 21:30:10 2011 +0000
- Revision:
- 0:3e7d6f496a67
- Child:
- 1:b05231650f32
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
sivan_toledo | 0:3e7d6f496a67 | 1 | #include "HTTPServer.h" |
sivan_toledo | 0:3e7d6f496a67 | 2 | |
sivan_toledo | 0:3e7d6f496a67 | 3 | class HttpHandlerUsbBrowser : public HTTPRequestHandler |
sivan_toledo | 0:3e7d6f496a67 | 4 | { |
sivan_toledo | 0:3e7d6f496a67 | 5 | public: |
sivan_toledo | 0:3e7d6f496a67 | 6 | HttpHandlerUsbBrowser(const char* rootPath, const char* path, TCPSocket* pTcpSocket); |
sivan_toledo | 0:3e7d6f496a67 | 7 | virtual ~HttpHandlerUsbBrowser(); |
sivan_toledo | 0:3e7d6f496a67 | 8 | |
sivan_toledo | 0:3e7d6f496a67 | 9 | static inline HTTPRequestHandler* inst(const char* rootPath, const char* path, TCPSocket* pTcpSocket) { return new HttpHandlerUsbBrowser(rootPath, path, pTcpSocket); } |
sivan_toledo | 0:3e7d6f496a67 | 10 | |
sivan_toledo | 0:3e7d6f496a67 | 11 | protected: |
sivan_toledo | 0:3e7d6f496a67 | 12 | |
sivan_toledo | 0:3e7d6f496a67 | 13 | virtual void doGet(); |
sivan_toledo | 0:3e7d6f496a67 | 14 | virtual void doPost(); |
sivan_toledo | 0:3e7d6f496a67 | 15 | virtual void doHead(); |
sivan_toledo | 0:3e7d6f496a67 | 16 | |
sivan_toledo | 0:3e7d6f496a67 | 17 | virtual void onReadable(); //Data has been read |
sivan_toledo | 0:3e7d6f496a67 | 18 | virtual void onWriteable(); //Data has been written & buf is free |
sivan_toledo | 0:3e7d6f496a67 | 19 | virtual void onClose(); //Connection is closing |
sivan_toledo | 0:3e7d6f496a67 | 20 | }; |