public class CommandLine
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
FMPP_CONSOLE_COLS
The number of console (terminal) columns can be passed in with this environment variable, supposedly by the
OS-specific starter executable (shell script).
|
Constructor and Description |
---|
CommandLine() |
Modifier and Type | Method and Description |
---|---|
static int |
execute(java.lang.String[] args,
java.io.PrintWriter stdout,
java.io.PrintWriter stderr)
Emulates the command-line invocation of the tool.
|
static void |
main(java.lang.String[] args)
Runs the command line interface.
|
public static final java.lang.String FMPP_CONSOLE_COLS
Settings.NAME_COLUMNS
is set, that will
override this (but by default it isn't set). The value of the environment variable should be just an integer
(with possible white space around it), however, if it's not a number, CommandLine
will attempt to parse
it as the output of the Windows mode con /status
command (also then [BR]
can be used instead of
real line-breaks, to ease bat programming). On UN*X-es usually this should be the output of tput cols
.public static void main(java.lang.String[] args)
FMPP_CONSOLE_COLS
public static int execute(java.lang.String[] args, java.io.PrintWriter stdout, java.io.PrintWriter stderr)
args
- the command line argumentsstdout
- the PrintWriter
used as stdout.
If it is null
then it defaults to the real stdout.stderr
- the PrintWriter
used as stderr.
If it is null
then it defaults to the real stderr.