Thrill
0.1
|
A class which creates a temporary directory in the current directory and returns it via get().
When the object is destroyed the temporary directory is wiped non-recursively.
Definition at line 26 of file temporary_directory.hpp.
#include <temporary_directory.hpp>
Public Member Functions | |
TemporaryDirectory () | |
TemporaryDirectory (const TemporaryDirectory &)=delete | |
non-copyable: delete copy-constructor More... | |
~TemporaryDirectory () | |
const std::string & | get () const |
return the temporary directory name More... | |
TemporaryDirectory & | operator= (const TemporaryDirectory &)=delete |
non-copyable: delete assignment operator More... | |
void | wipe () const |
wipe contents of directory More... | |
Static Public Member Functions | |
static std::string | make_directory (const char *sample="thrill-testsuite-") |
Create a temporary directory, returns its name without trailing /. More... | |
static void | wipe_directory (const std::string &tmp_dir, bool do_rmdir) |
wipe temporary directory NON RECURSIVELY! More... | |
Private Attributes | |
std::string | dir_ |
|
inline |
Definition at line 35 of file temporary_directory.hpp.
Referenced by TemporaryDirectory::~TemporaryDirectory().
|
inline |
Definition at line 39 of file temporary_directory.hpp.
References TemporaryDirectory::dir_, TemporaryDirectory::operator=(), TemporaryDirectory::TemporaryDirectory(), and TemporaryDirectory::wipe_directory().
|
delete |
non-copyable: delete copy-constructor
|
inline |
return the temporary directory name
Definition at line 49 of file temporary_directory.hpp.
References TemporaryDirectory::dir_.
|
static |
Create a temporary directory, returns its name without trailing /.
Definition at line 100 of file temporary_directory.cpp.
|
delete |
non-copyable: delete assignment operator
Referenced by TemporaryDirectory::~TemporaryDirectory().
|
inline |
wipe contents of directory
Definition at line 52 of file temporary_directory.hpp.
References TemporaryDirectory::dir_, and TemporaryDirectory::wipe_directory().
|
static |
wipe temporary directory NON RECURSIVELY!
Definition at line 115 of file temporary_directory.cpp.
References sLOG1, and thrill::common::ts_readdir().
Referenced by TemporaryDirectory::wipe(), and TemporaryDirectory::~TemporaryDirectory().
|
private |
Definition at line 57 of file temporary_directory.hpp.
Referenced by TemporaryDirectory::get(), TemporaryDirectory::wipe(), and TemporaryDirectory::~TemporaryDirectory().