throw new CommandValidationException(
strings.get("missingOptions", name));
int operandMin = 0;
int operandMax = 0;
ParamModel operandParam = getOperandModel();
if (operandParam != null) {
operandMin = operandParam.getParam().optional() ? 0 : 1;
operandMax = operandParam.getParam().multiple() ?
Integer.MAX_VALUE : 1;
}
if (operands.size() < operandMin && cons != null) {
cons.printf("%s",
strings.get("operandPrompt", operandParam.getName()));
String val = cons.readLine();
if (ok(val)) {
operands = new ArrayList<String>();
operands.add(val);
}
}
if (operands.size() < operandMin)
throw new CommandValidationException(
strings.get("notEnoughOperands", name,
operandParam.getType()));
if (operands.size() > operandMax) {
if (operandMax == 0)
throw new CommandValidationException(
strings.get("noOperandsAllowed", name));
else if (operandMax == 1)