- java.lang.Object
-
- com.pervasive.datarush.commons.util.ProcessBuilders
-
public final class ProcessBuilders extends Object
Provides various utilities to use when working with theProcessBuilder
class.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ProcessBuilder
builder(List<String> args)
Quotes command line args, performing proper escaping.static String
quote(String arg)
Quotes command a line argument, performing proper escaping.static List<String>
quote(List<String> args)
Quotes command line args, performing proper escaping.
-
-
-
Method Detail
-
builder
public static ProcessBuilder builder(List<String> args)
Quotes command line args, performing proper escaping. This is necessary to workaround a bug on windows where arguments are not being property escaped.- Parameters:
args
- the list of unquoted arguments- Returns:
- a ProcessBuilder with the args quoted
-
quote
public static List<String> quote(List<String> args)
Quotes command line args, performing proper escaping. This is necessary to workaround a bug on windows where arguments are not being property escaped.- Parameters:
args
- the list of unquoted arguments- Returns:
- the quoted arguments
-
-