-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCopyDir.h
30 lines (22 loc) · 886 Bytes
/
CopyDir.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#pragma once
#ifndef MESSMER_COPYFS_SRC_COPYDIR_H_
#define MESSMER_COPYFS_SRC_COPYDIR_H_
#include "CopyNode.h"
#include <messmer/fspp/fs_interface/Dir.h>
#include <messmer/fspp/fs_interface/File.h>
namespace copyfs {
class CopyDir final: public fspp::Dir, CopyNode {
public:
CopyDir(CopyDevice *device, const bf::path &path);
~CopyDir();
//TODO return type variance to CopyFile/CopyDir?
cpputils::unique_ref<fspp::OpenFile> createAndOpenFile(const std::string &name, mode_t mode, uid_t uid, gid_t gid) override;
void createDir(const std::string &name, mode_t mode, uid_t uid, gid_t gid) override;
void createSymlink(const std::string &name, const boost::filesystem::path &target, uid_t uid, gid_t gid) override;
void remove() override;
cpputils::unique_ref<std::vector<Entry>> children() const override;
private:
DISALLOW_COPY_AND_ASSIGN(CopyDir);
};
}
#endif