mirror of
https://github.com/itplr-kosit/validator.git
synced 2026-05-25 16:55:39 +00:00
further doc
This commit is contained in:
parent
06a88848db
commit
997f5073fe
4 changed files with 49 additions and 34 deletions
|
|
@ -29,7 +29,6 @@ import java.util.Arrays;
|
|||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.StreamSupport;
|
||||
|
||||
import org.apache.commons.cli.CommandLine;
|
||||
import org.apache.commons.cli.CommandLineParser;
|
||||
|
|
@ -97,6 +96,9 @@ public class CommandLineApplication {
|
|||
private static final Option WORKER_COUNT = Option.builder("T").longOpt("threads").hasArg()
|
||||
.desc("Number of threads processing validation requests").build();
|
||||
|
||||
private static final Option DISABLE_GUI = Option.builder("G").longOpt("disable-gui").desc("Disables the GUI of the daemon mode")
|
||||
.build();
|
||||
|
||||
public static final int DAEMON_SIGNAL = 100;
|
||||
|
||||
private static final Option PRINT_MEM_STATS = Option.builder("m").longOpt("memory-stats").desc("Prints some memory stats").build();
|
||||
|
|
@ -175,6 +177,9 @@ public class CommandLineApplication {
|
|||
warnUnusedOptions(cmd, unavailable, true);
|
||||
final ConfigurationLoader config = Configuration.load(determineDefinition(cmd), determineRepository(cmd));
|
||||
final Daemon validDaemon = new Daemon(determineHost(cmd), determinePort(cmd), determineThreads(cmd));
|
||||
if (cmd.hasOption(DISABLE_GUI.getOpt())) {
|
||||
validDaemon.setGuiEnabled(false);
|
||||
}
|
||||
validDaemon.startServer(config.build());
|
||||
return DAEMON_SIGNAL;
|
||||
}
|
||||
|
|
@ -379,6 +384,7 @@ public class CommandLineApplication {
|
|||
options.addOption(CHECK_ASSERTIONS);
|
||||
options.addOption(PRINT_MEM_STATS);
|
||||
options.addOption(WORKER_COUNT);
|
||||
options.addOption(DISABLE_GUI);
|
||||
return options;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue