2015-11-03 21:20:15 +01:00
|
|
|
#pragma once
|
|
|
|
#ifndef MESSMER_CPPUTILS_PROCESS_SUBPROCESS_H
|
|
|
|
#define MESSMER_CPPUTILS_PROCESS_SUBPROCESS_H
|
|
|
|
|
|
|
|
#include <string>
|
|
|
|
|
|
|
|
namespace cpputils {
|
|
|
|
//TODO Test
|
|
|
|
class Subprocess {
|
|
|
|
public:
|
|
|
|
static std::string call(const std::string &command);
|
2015-11-03 22:11:09 +01:00
|
|
|
static int callAndGetReturnCode(const std::string &command);
|
|
|
|
private:
|
|
|
|
static FILE* _call(const std::string &command);
|
2015-11-03 21:20:15 +01:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|