diff options
author | Vlad Yaroslavlev <vladon@vladon.com> | 2022-02-10 16:46:25 +0300 |
---|---|---|
committer | Daniil Cherednik <dcherednik@yandex-team.ru> | 2022-02-10 16:46:25 +0300 |
commit | 344ea37b4a345701ab0e67de2266a1c1bd7baf2d (patch) | |
tree | 1a2c5ffcf89eb53ecd79dbc9bc0a195c27404d0c /util/system/tempfile.h | |
parent | 706b83ed7de5a473436620367af31fc0ceecde07 (diff) | |
download | ydb-344ea37b4a345701ab0e67de2266a1c1bd7baf2d.tar.gz |
Restoring authorship annotation for Vlad Yaroslavlev <vladon@vladon.com>. Commit 2 of 2.
Diffstat (limited to 'util/system/tempfile.h')
-rw-r--r-- | util/system/tempfile.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/util/system/tempfile.h b/util/system/tempfile.h index e20f792371..de249c129d 100644 --- a/util/system/tempfile.h +++ b/util/system/tempfile.h @@ -4,31 +4,31 @@ #include "file.h" #include <util/folder/path.h> -#include <util/generic/string.h> +#include <util/generic/string.h> class TTempFile { public: - inline TTempFile(const TString& fname) + inline TTempFile(const TString& fname) : Name_(fname) { } - inline ~TTempFile() { + inline ~TTempFile() { NFs::Remove(Name()); } - inline const TString& Name() const noexcept { + inline const TString& Name() const noexcept { return Name_; } private: - const TString Name_; + const TString Name_; }; class TTempFileHandle: public TTempFile, public TFile { public: TTempFileHandle(); - TTempFileHandle(const TString& fname); + TTempFileHandle(const TString& fname); static TTempFileHandle InCurrentDir(const TString& filePrefix = "yandex", const TString& extension = "tmp"); static TTempFileHandle InDir(const TFsPath& dirPath, const TString& filePrefix = "yandex", const TString& extension = "tmp"); |