Closed polopi closed 9 years ago
See also #20 #21 The method request an int as defaultValue value
int
static int promptOptions(String message, int defaultValue, List options = [])
then in readLine, it returns the int
readLine
return System.console().readLine(_message) ?: defaultValue
and then tries to call parseInt on it
parseInt
int choice = Integer.parseInt(readLine(consoleMessage, defaultValue))
Finally you end up with that kind of error : No signature of method: static java.lang.Integer.parseInt() is applicable for argument types: (java.lang.Integer) values: [0]
See also #20 #21 The method request an
int
as defaultValue valuethen in
readLine
, it returns theint
and then tries to call
parseInt
on itFinally you end up with that kind of error : No signature of method: static java.lang.Integer.parseInt() is applicable for argument types: (java.lang.Integer) values: [0]