blob: d7f348660c236f5f4fe84450767755837fbc7877 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
#pragma once
#include <yql/essentials/utils/rand_guid.h>
#include <util/generic/hash.h>
#include <util/folder/path.h>
namespace NYql {
namespace NCommon {
/*
Resembles sandbox for external UDFs
*/
class TFilesBox {
public:
TFilesBox(TFsPath dir, TRandGuid randGuid);
~TFilesBox();
TString MakeLinkFrom(const TString& source, const TString& filename = {});
TString GetDir() const;
void Destroy();
private:
TFsPath Dir;
TRandGuid RandGuid;
THashMap<TString, TString> Mapping;
};
THolder<TFilesBox> CreateFilesBox(const TFsPath& baseDir);
}
}
|