|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.dtolabs.rundeck.core.execution.ExecArgList
public class ExecArgList
A list of commandline arguments, with flags to indicate quoting.
Nested Class Summary | |
---|---|
static class |
ExecArgList.Builder
Builder class |
Method Summary | |
---|---|
java.lang.String[] |
asFlatStringArray()
Flatten the list of arguments into an array |
java.util.ArrayList<java.lang.String> |
asFlatStringList()
Flatten the list of arguments into a list |
java.util.ArrayList<java.lang.String> |
buildCommandForNode(java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> dataContext,
java.lang.String osFamily)
Generate the quoted and expanded argument list, by expanding property values given the data context, and quoting for the given OS |
static ExecArgList.Builder |
builder()
Create a Builder |
static ExecArgList |
fromStrings(boolean quoted,
java.lang.String... args)
|
static ExecArgList |
fromStrings(java.util.List<java.lang.String> strings,
boolean quoted)
Create an ExecArgList from a list of strings |
static ExecArgList |
fromStrings(org.apache.commons.collections.Predicate quoteDetect,
java.lang.String... args)
Create an ExecArgList from a list of strings, and a predicate to determine whether the argument needs to be quoted |
java.util.List<ExecArg> |
getList()
Return the list of ExecArg objects |
static java.lang.String |
joinAndQuote(java.util.List<java.lang.String> commandList1,
Converter<java.lang.String,java.lang.String> quote)
Join a list of strings and then quote the entire string, if specified |
void |
visitWith(ExecArg.Visitor visitor)
Visit with a visitor |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static ExecArgList fromStrings(boolean quoted, java.lang.String... args)
public static ExecArgList fromStrings(org.apache.commons.collections.Predicate quoteDetect, java.lang.String... args)
quoteDetect
- args
-
public static ExecArgList fromStrings(java.util.List<java.lang.String> strings, boolean quoted)
strings
- the stringsquoted
- whether they are each quoted
public java.util.List<ExecArg> getList()
public java.lang.String[] asFlatStringArray()
public java.util.ArrayList<java.lang.String> asFlatStringList()
public static java.lang.String joinAndQuote(java.util.List<java.lang.String> commandList1, Converter<java.lang.String,java.lang.String> quote)
commandList1
- quote
-
public java.util.ArrayList<java.lang.String> buildCommandForNode(java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> dataContext, java.lang.String osFamily)
dataContext
- property value data contextosFamily
- OS family to determine quoting
public static ExecArgList.Builder builder()
public void visitWith(ExecArg.Visitor visitor)
visitor
-
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |