similarity index 82%rename from src/net/curisit/securis/License.javarename to src/main/java/net/curisit/securis/License.java| .. | .. |
|---|
| 7 | 7 | import org.apache.commons.cli.Options; |
|---|
| 8 | 8 | import org.apache.commons.cli.ParseException; |
|---|
| 9 | 9 | import org.apache.commons.cli.PosixParser; |
|---|
| 10 | +import org.slf4j.Logger; |
|---|
| 11 | +import org.slf4j.LoggerFactory; |
|---|
| 10 | 12 | |
|---|
| 11 | 13 | public class License { |
|---|
| 14 | + |
|---|
| 15 | + private static final Logger log = LoggerFactory.getLogger(License.class); |
|---|
| 12 | 16 | |
|---|
| 13 | 17 | public static void main(String[] args) { |
|---|
| 14 | 18 | CommandLine cmd = getCommandLine(args); |
|---|
| .. | .. |
|---|
| 47 | 51 | options.addOption("h", "help", false, "Show help."); |
|---|
| 48 | 52 | options.addOption(OptionBuilder.withArgName("req_file").withLongOpt("rfile").withDescription("Set request file for its generation or for license requesting.").hasArg(true).create('r')); |
|---|
| 49 | 53 | options.addOption(OptionBuilder.withArgName("url_license_server").withLongOpt("server").withDescription("License server url.").hasArg(true).create('s')); |
|---|
| 50 | | - options.addOption(OptionBuilder.withArgName("lic_file").withLongOpt("license").withDescription("Validate lic file.").hasArg(true).create('l')); |
|---|
| 54 | + options.addOption(OptionBuilder.withArgName("lic_file").withLongOpt("validate").withDescription("Validate lic file.").hasArg(true).create('l')); |
|---|
| 51 | 55 | |
|---|
| 52 | 56 | options.addOption("g", "gen_request", false, "Generate request file. If --rfile parameter is missing then It is generated in current directory."); |
|---|
| 53 | 57 | options.addOption("c", "create", false, "Request a license file from server. --rfile and --server parameters are mandatory."); |
|---|
| 54 | 58 | options.addOption("t", "test_lc", false, "Test if License Server (LC) is available. --server parameter is mandatory."); |
|---|
| 59 | + options.addOption(OptionBuilder.withArgName("lic_file").withLongOpt("sync").withDescription("Synchronize/renew the current license file. --server parameter is mandatory.").hasArg(true).create('y')); |
|---|
| 55 | 60 | |
|---|
| 56 | 61 | return options; |
|---|
| 57 | 62 | } |
|---|