导出数据转spine
This commit is contained in:
1 parent
d258d4f435
commit
3a7c0b4092
65 files changed
+6000
No files matched your search
@@ -0,0 +1,35 @@
|
||||
#pragma once
|
||||
|
||||
#include <chrono>
|
||||
#include <filesystem>
|
||||
#include <memory>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
|
||||
namespace dts {
|
||||
|
||||
struct ProcessRequest {
|
||||
std::filesystem::path program;
|
||||
std::vector<std::string> arguments;
|
||||
std::filesystem::path workingDirectory;
|
||||
std::chrono::milliseconds timeout{10000};
|
||||
};
|
||||
|
||||
struct ProcessResult {
|
||||
bool started = false;
|
||||
bool timedOut = false;
|
||||
int exitCode = -1;
|
||||
std::string output;
|
||||
std::string error;
|
||||
};
|
||||
|
||||
class IProcessRunner {
|
||||
public:
|
||||
virtual ~IProcessRunner() = default;
|
||||
[[nodiscard]] virtual ProcessResult run(const ProcessRequest& request) const = 0;
|
||||
};
|
||||
|
||||
[[nodiscard]] std::unique_ptr<IProcessRunner> createDefaultProcessRunner();
|
||||
|
||||
} // namespace dts
|
||||
|
||||
Reference in new issue
Block a user