2020-06-24 20:03:38 +00:00
|
|
|
#ifndef WFP_TEST_UTIL_WEBFUSE_SERVER_HPP
|
|
|
|
#define WFP_TEST_UTIL_WEBFUSE_SERVER_HPP
|
|
|
|
|
|
|
|
#include <string>
|
|
|
|
|
|
|
|
namespace webfuse_test
|
|
|
|
{
|
|
|
|
|
|
|
|
class WebfuseServer
|
|
|
|
{
|
|
|
|
WebfuseServer(WebfuseServer const &) = delete;
|
|
|
|
WebfuseServer& operator=(WebfuseServer const &) = delete;
|
|
|
|
public:
|
2020-06-25 16:36:51 +00:00
|
|
|
WebfuseServer(bool use_tls = false);
|
2020-06-24 20:03:38 +00:00
|
|
|
~WebfuseServer();
|
|
|
|
std::string const & GetUrl();
|
2020-07-12 09:09:50 +00:00
|
|
|
std::string Invoke(std::string const & method, std::string const & params);
|
|
|
|
std::string Lookup(int parent, std::string const & name);
|
|
|
|
std::string Open(int inode, int flags);
|
|
|
|
std::string Read(int inode, int handle, int offset, int length);
|
|
|
|
std::string ReadDir(int inode);
|
2020-06-24 20:03:38 +00:00
|
|
|
private:
|
|
|
|
class Private;
|
|
|
|
Private * d;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|