18#include "absl/log/check.h"
19#include "absl/strings/str_cat.h"
20#include "absl/time/time.h"
25std::string
TempFile(absl::string_view prefix) {
28 path = absl::StrCat(absl::ToUnixMicros(absl::Now()));
30 path = absl::StrCat(prefix,
"_", absl::ToUnixMicros(absl::Now()));
42 : path_(
file::TempFile(prefix)) {
50 path_ = std::move(rhs.path_);
62 if (dirname.empty()) {
77 *status = Init(options);
static TempPath * Create(Location location)
static constexpr int kDefaultMode
default mode to create directories (a+rwx):
TempPath(absl::string_view prefix)
std::string path() const
Returns the path which was created by this object.
TempPath & operator=(TempPath &&rhs)
absl::Status RecursivelyCreateDir(std::string_view path, const file::Options &options)
std::string TempFile(absl::string_view prefix)