|
ISIS Core Library 0.7.2 (api 3.0.0)
|
Class to automatically create and handle a temporary file. More...
#include <tmpfile.hpp>
Public Member Functions | |
| TmpFile (std::string prefix="", std::string suffix="") | |
| Create a temporary file. | |
| ~TmpFile () | |
| Will delete the temporary file if its still there. | |
Class to automatically create and handle a temporary file.
This can e.g. be used when writing plugins for image formats to have a mock object. The file will be created by the constructor and deleted by the destructor. If its not there anymore, a warning will be send. This inherits from boost::filesystem::path and thus can be used as such.
Definition at line 35 of file tmpfile.hpp.
| isis::util::TmpFile::TmpFile | ( | std::string | prefix = "", |
| std::string | suffix = "" |
||
| ) |
Create a temporary file.
This generates a temporary filename using the given prefix and suffix. The file will also be created to prevent any following calls from generating the same filename.
| prefix | string to be inserted between the path and the actual filename |
| suffix | string to be appended to the filename |
Definition at line 38 of file tmpfile.cpp.
| isis::util::TmpFile::~TmpFile | ( | ) |
Will delete the temporary file if its still there.
Definition at line 47 of file tmpfile.cpp.
1.7.3