@CommandDefinition(name = "test", description = "a simple test") public class TestPopulator3<CI extends CommandInvocation> implements Command<CI> { @OptionGroup(shortName = 'b') private Map<String, String> basicMap; @OptionGroup(shortName = 'i') private TreeMap<String, Integer> integerMap; public TestPopulator3() { } public Map<String,String> getBasicMap() { return basicMap; } public Map<String, Integer> getIntegerMap() { return integerMap; } @Override public CommandResult execute(CI commandInvocation) throws CommandException, InterruptedException { return CommandResult.SUCCESS; } }
private Set<String> basicSet; @OptionGroup(shortName = 'D', description = "define properties") private TreeMap<String, Integer> define;
@CommandDefinition(name = "test", description = "a simple test", aliases = {"toto"}) public class Parser1Test<CI extends CommandInvocation> extends TestingCommand<CI> { @Option(shortName = 'X', name = "X", description = "enable X", hasValue = false) private Boolean enableX; @Option(shortName = 'f', name = "foo", description = "enable foo", hasValue = false) private Boolean foo; @Option(shortName = 'e', name = "equal", description = "enable equal", required = true) private String equal; @Option(shortName = 'c') private int connection; @OptionGroup(shortName = 'D', description = "define properties", required = true) private Map<String,String> define; @Arguments private List<String> arguments; }
private Set<String> basicSet; @OptionGroup(shortName = 'D', description = "define properties") private TreeMap<String, Integer> define;