[SHELLBTRFS] Upgrade to 1.5
[reactos.git] / dll / shellext / shellbtrfs / mountmgr_local.h
diff --git a/dll/shellext/shellbtrfs/mountmgr_local.h b/dll/shellext/shellbtrfs/mountmgr_local.h
new file mode 100644 (file)
index 0000000..c26566b
--- /dev/null
@@ -0,0 +1,34 @@
+#pragma once
+
+#include <vector>
+#include <string>
+#include <sstream>
+#ifndef __REACTOS__
+#include <string_view>
+#else
+#define string_view string
+#define wstring_view wstring
+#endif
+#include <iostream>
+#include <iomanip>
+
+class mountmgr_point {
+public:
+    mountmgr_point(const std::wstring_view& symlink, const std::string_view& unique_id, const std::wstring_view& device_name) : symlink(symlink), device_name(device_name), unique_id(unique_id) {
+    }
+
+    std::wstring symlink, device_name;
+    std::string unique_id;
+};
+
+class mountmgr {
+public:
+    mountmgr();
+    ~mountmgr();
+    void create_point(const std::wstring_view& symlink, const std::wstring_view& device) const;
+    void delete_points(const std::wstring_view& symlink, const std::wstring_view& unique_id = L"", const std::wstring_view& device_name = L"") const;
+    std::vector<mountmgr_point> query_points(const std::wstring_view& symlink = L"", const std::wstring_view& unique_id = L"", const std::wstring_view& device_name = L"") const;
+
+private:
+    HANDLE h;
+};