public class OmeCliCommandPrinter
extends java.lang.Object
OME CLI command, masking the
values of selected options if desired.| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
mask
The string used to replace the value of an option to mask.
|
| Constructor and Description |
|---|
OmeCliCommandPrinter(util.runtime.CommandBuilder command)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
print()
Pretty-prints the command to a string.
|
java.lang.String |
printMasking(java.lang.Integer... index)
Pretty-prints the command to a string, masking the token at the
specified index.
|
java.lang.String |
printMasking(java.lang.String... optionName)
Pretty-prints the command to a string, masking the value of each
specified option.
|
public static final java.lang.String mask
public OmeCliCommandPrinter(util.runtime.CommandBuilder command)
command - the command to pretty-print.java.lang.NullPointerException - if the command is null.public java.lang.String print()
public java.lang.String printMasking(java.lang.String... optionName)
optionName - name of an option whose value has to be masked when
printing; if no list is given, nothing will be masked.public java.lang.String printMasking(java.lang.Integer... index)
index - index of a token to mask when printing; if no list is given,
nothing will be masked.