diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2021-05-16 01:14:29 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2021-05-16 01:14:29 +0300 |
commit | 1f7066186a040243fc3b4132f7b19af5d894bc5a (patch) | |
tree | 42470f6aebe62cec049c3d2c8a2248f27b4ffed2 /include | |
parent | File: add get_size/query_id (diff) | |
download | winapi-common-1f7066186a040243fc3b4132f7b19af5d894bc5a.tar.gz winapi-common-1f7066186a040243fc3b4132f7b19af5d894bc5a.zip |
File: make public child of Handle
Diffstat (limited to 'include')
-rw-r--r-- | include/winapi/file.hpp | 19 |
1 files changed, 7 insertions, 12 deletions
diff --git a/include/winapi/file.hpp b/include/winapi/file.hpp index 78187d9..e9f8510 100644 --- a/include/winapi/file.hpp +++ b/include/winapi/file.hpp @@ -21,7 +21,7 @@ namespace winapi { bool operator==(const FILE_ID_128& a, const FILE_ID_128& b); -class File : private Handle { +class File : public Handle { public: struct ID { const FILE_ID_INFO impl; @@ -32,23 +32,18 @@ public: } }; - static Handle open_r(const std::string&); - static Handle open_r(const CanonicalPath&); - static Handle open_read_attributes(const std::string&); - static Handle open_read_attributes(const CanonicalPath&); - static Handle open_w(const std::string&); - static Handle open_w(const CanonicalPath&); + static File open_r(const std::string&); + static File open_r(const CanonicalPath&); + static File open_read_attributes(const std::string&); + static File open_read_attributes(const CanonicalPath&); + static File open_w(const std::string&); + static File open_w(const CanonicalPath&); static void remove(const std::string&); static void remove(const CanonicalPath&); explicit File(Handle&& handle) : Handle(std::move(handle)) {} - using Handle::close; - - using Handle::read; - using Handle::write; - std::size_t get_size() const; ID query_id() const; |