Package org.aksw.jenax.engine.qlever
Class SystemUtils
java.lang.Object
org.aksw.jenax.engine.qlever.SystemUtils
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic InputStreamexec(ProcessBuilder processBuilder) static InputStreamstatic InputStreamstatic voidfailIfNonZero(int exitValue) static voidfailIfNonZero(Process process) static StringgetCommandOutput(String... command) static intgetGID()static intgetUID()static Processrun(ProcessBuilder processBuilder, Consumer<String> logger) static Processstatic voidrunAndWait(Consumer<String> logger, String... cmd) static String
-
Constructor Details
-
SystemUtils
public SystemUtils()
-
-
Method Details
-
exec
- Throws:
IOExceptionInterruptedException
-
exec
- Throws:
IOExceptionInterruptedException
-
run
public static Process run(Consumer<String> logger, String... cmd) throws IOException, InterruptedException - Throws:
IOExceptionInterruptedException
-
run
public static Process run(ProcessBuilder processBuilder, Consumer<String> logger) throws IOException, InterruptedException - Throws:
IOExceptionInterruptedException
-
runAndWait
- Throws:
IOException
-
failIfNonZero
-
failIfNonZero
public static void failIfNonZero(int exitValue) -
exec
public static InputStream exec(ProcessBuilder processBuilder) throws IOException, InterruptedException - Throws:
IOExceptionInterruptedException
-
getCommandOutput
- Throws:
IOException
-
which
- Throws:
IOException
-
getUID
-
getGID
-