libfoedus-core
FOEDUS Core Library
|
#include "foedus/fs/filesystem.hpp"
#include <dirent.h>
#include <fcntl.h>
#include <stdint.h>
#include <unistd.h>
#include <sys/stat.h>
#include <sys/types.h>
#include <sys/vfs.h>
#include <chrono>
#include <cstdio>
#include <cstdlib>
#include <ctime>
#include <iostream>
#include <string>
#include <vector>
#include "foedus/assert_nd.hpp"
#include "foedus/engine.hpp"
#include "foedus/engine_options.hpp"
#include "foedus/assorted/assorted_func.hpp"
#include "foedus/debugging/debugging_supports.hpp"
#include "foedus/fs/path.hpp"
Go to the source code of this file.
Namespaces | |
foedus | |
Root package of FOEDUS (Fast Optimistic Engine for Data Unification Services). | |
foedus::fs | |
Filesystem wrapper, an analogue of boost::filesystem. | |
Functions | |
FileStatus | foedus::fs::status (const Path &p) |
Returns the status of the file. More... | |
Path | foedus::fs::absolute (const std::string &p) |
Returns the absolue path of the specified path. More... | |
Path | foedus::fs::current_path () |
Returns the current working directory. More... | |
Path | foedus::fs::home_path () |
Returns the absolute path of the home directory of the user running this process. More... | |
bool | foedus::fs::create_directories (const Path &p, bool sync=false) |
Recursive mkdir (mkdirs). More... | |
bool | foedus::fs::create_directory (const Path &p, bool sync=false) |
mkdir. More... | |
uint64_t | foedus::fs::file_size (const Path &p) |
Returns size of the file. More... | |
bool | foedus::fs::remove (const Path &p) |
Deletes a regular file or an empty directory. More... | |
uint64_t | foedus::fs::remove_all (const Path &p) |
Recursively deletes a directory. More... | |
SpaceInfo | foedus::fs::space (const Path &p) |
Returns free space information for the device the file is on. More... | |
std::string | foedus::fs::unique_name (uint64_t differentiator=0) |
Equivalent to unique_path("%%%%-%%%%-%%%%-%%%%"). More... | |
std::string | foedus::fs::unique_name (const std::string &model, uint64_t differentiator=0) |
Returns a randomly generated file name with the given template. More... | |
std::ostream & | foedus::fs::operator<< (std::ostream &o, const SpaceInfo &v) |
bool | foedus::fs::atomic_rename (const Path &old_path, const Path &new_path) |
Renames the old file to the new file with the POSIX atomic-rename semantics. More... | |
bool | foedus::fs::fsync (const Path &path, bool sync_parent_directory=false) |
Makes the content and metadata of the file durable all the way up to devices. More... | |
bool | foedus::fs::durable_atomic_rename (const Path &old_path, const Path &new_path) |
fsync() on source file before rename, then fsync() on the parent folder after rename. More... | |