I have the following code:
val actions = Map(
"index" -> Map(
"description" -> "Makes CAEServer index project with provided project_id "
, "usage" -> "index project_id"
, "action" -> (
(args: Array[String]) => {
if (checkSecondArgument(args, "Project ID wasn't specified. Please supply project ID.")) {
new CAEServer(args{0}).index(args{2})
}
}
)))
actions{providedAction}{"action"}(args)
and when I'm trying to compile it, compiler says
error: MainConsole.this.actions.apply(providedAction).apply("action") of type java.lang.Object does not take parameters
[INFO] actions{providedAction}{"action"}(args)
[INFO] ^
[ERROR] one error found
What's wrong?
Map[String, Map[String, Any]]whereAnydoesn't take parameters.