httpServer Library with Ethernet
Dependents: Simple_HTTP_JSON HTTPWebServer-WIZwiki-W7500 HTTPWebServer-WIZwiki-W750023 WIZ750SR_test
Fork of httpServer by
Diff: Handler/FsHandler.h
- Revision:
- 2:dd293a10a772
- Parent:
- 0:e59cc54df17c
--- a/Handler/FsHandler.h Tue Jun 30 00:21:41 2015 +0000 +++ b/Handler/FsHandler.h Wed Sep 02 02:03:22 2015 +0000 @@ -25,8 +25,11 @@ #include "mbed.h" #include "HTTPRequestHandler.h" +#include "HTTPConnection.h" +#include "EthernetInterface.h" #include <map> +#include <list> #include <string> /** class HTTPFsRequestHandler serves requests with file-system objects @@ -37,6 +40,7 @@ std::string m_localPath; public: + /** constructor for HTTPFsRequestHandler object and stores the request related data locally. * the request handling will be initiated from within the constructor. * @param rootPath : The path under which the handler was registered. @@ -74,10 +78,15 @@ */ static void mount(const char* requestPath, const char* localPath) { m_fsMap[requestPath] = localPath; } + //Test + //static std::list<EthernetInterface> m_eth_list; + static std::map<int, EthernetInterface*> m_eth_list; + static void mount_eth(EthernetInterface* eth) { m_eth_list[0] = eth; } + /** Parse a uri string for uri file name and argument:value pairs */ int parseUriArgs(string uri, map<string, string>& args); uint32_t get_http_param_value(char* param_name); }; -#endif // __FSHANDLER_H__ \ No newline at end of file +#endif // __FSHANDLER_H__