|
Crombie Tools
|
Functions | |
| std::string | basename (const std::string &name) |
| bool | confirm_overwrite (const std::string &path) |
| If this would overwrite a directory that exists, ask for confirmation. More... | |
| std::string | dirname (const std::string &name) |
| bool | exists (const std::string &path) |
| Check if path exists (either directory or file) More... | |
| unsigned long | get_size (const std::string &name) |
| Get the size of a file. More... | |
| Types::strings | list (std::string directory) |
| The name of files inside of the directory. More... | |
| void | mkdirs (const std::string &path) |
| Create directories, recursively if needed. More... | |
| std::string crombie::FileSystem::basename | ( | const std::string & | name | ) |
Definition at line 18 of file FileSystem.h.
References Debug::Debug(), and crombie::Misc::split().
Referenced by dirname().
| bool crombie::FileSystem::confirm_overwrite | ( | const std::string & | path | ) |
If this would overwrite a directory that exists, ask for confirmation.
This returns whether or not the user confirms the file to be removed.
Definition at line 152 of file FileSystem.h.
References exists().
| std::string crombie::FileSystem::dirname | ( | const std::string & | name | ) |
Definition at line 24 of file FileSystem.h.
References basename(), Debug::Debug(), link::filename, crombie::Misc::shell(), crombie::Misc::split(), and crombie::Misc::tokenize().
Referenced by crombie::FileConfig::FileConfig::get_dirs().
| bool crombie::FileSystem::exists | ( | const std::string & | path | ) |
Check if path exists (either directory or file)
Definition at line 87 of file FileSystem.h.
Referenced by confirm_overwrite(), crombie::Datacard::dumpplots(), crombie::FileConfig::DirectoryInfo::fillfiles(), and mkdirs().
| unsigned long crombie::FileSystem::get_size | ( | const std::string & | name | ) |
Get the size of a file.
Definition at line 95 of file FileSystem.h.
Referenced by crombie::FileConfig::FileInfo::FileInfo().
| Types::strings crombie::FileSystem::list | ( | std::string | directory | ) |
The name of files inside of the directory.
Definition at line 131 of file FileSystem.h.
Referenced by crombie::FileConfig::DirectoryInfo::fillfiles(), and CrombieTools.PlotTools.PlotStack.ParallelStackContainer::MakePlot().
| void crombie::FileSystem::mkdirs | ( | const std::string & | path | ) |
Create directories, recursively if needed.
Definition at line 104 of file FileSystem.h.
References exists().
Referenced by crombie::Datacard::dumpplots().