Rudiments

directory.h
1 // Copyright (c) 1999-2018 David Muse
2 // See the COPYING file for more information.
3
4 #ifndef RUDIMENTS_DIRECTORY_H
5 #define RUDIMENTS_DIRECTORY_H
6
7 #include <rudiments/private/directoryincludes.h>
8
11 class RUDIMENTS_DLLSPEC directory {
12 public:
14 directory();
15
17 ~directory();
18
20 bool open(const char *path);
21
23 bool close();
24
28 bool skip();
29
34 char *read();
35
38 void rewind();
39
42 uint64_t getChildCount();
43
49 char *getChildName(uint64_t index);
50
53 int64_t maxFileNameLength();
54
58 int64_t maxPathLength();
59
64 bool canExceedMaxFileNameLength();
65
67 static bool create(const char *path, mode_t perms);
68
78 static bool createTemporaryDirectory(
79 char *templatedirname, mode_t perms);
80
82 static bool remove(const char *path);
83
85 static bool removeTree(const char *path);
86
92 static char *getCurrentWorkingDirectory();
93
95 static bool changeDirectory(const char *path);
96
98 static bool changeRoot(const char *path);
99
102 static int64_t maxFileNameLength(const char *pathname);
103
106 static int64_t maxPathLength(const char *pathname);
107
112 static bool canExceedMaxFileNameLength(
113 const char *pathname);
114
115 #include <rudiments/private/directory.h>
116 };
117
118 #endif
directory
Definition: directory.h:11
directory::close
bool close()
directory::changeDirectory
static bool changeDirectory(const char *path)
directory::directory
directory()
directory::canExceedMaxFileNameLength
static bool canExceedMaxFileNameLength(const char *pathname)
directory::maxPathLength
static int64_t maxPathLength(const char *pathname)
directory::changeRoot
static bool changeRoot(const char *path)
directory::removeTree
static bool removeTree(const char *path)
directory::skip
bool skip()
directory::rewind
void rewind()
directory::read
char * read()
directory::getChildCount
uint64_t getChildCount()
directory::maxFileNameLength
int64_t maxFileNameLength()
directory::maxPathLength
int64_t maxPathLength()
directory::remove
static bool remove(const char *path)
directory::open
bool open(const char *path)
directory::canExceedMaxFileNameLength
bool canExceedMaxFileNameLength()
directory::createTemporaryDirectory
static bool createTemporaryDirectory(char *templatedirname, mode_t perms)
directory::create
static bool create(const char *path, mode_t perms)
directory::maxFileNameLength
static int64_t maxFileNameLength(const char *pathname)
directory::~directory
~directory()
directory::getCurrentWorkingDirectory
static char * getCurrentWorkingDirectory()
directory::getChildName
char * getChildName(uint64_t index)