CommandLauncher
wvlet.airframe.launcher.CommandLauncher
class CommandLauncher(val launcherInfo: LauncherInfo, val optionParser: OptionParser, val subCommands: Seq[CommandLauncher], defaultCommand: Option[LauncherInstance => Any]) extends CommandLauncherBaseCompat, LogSupport
Command launcher.
class MyCommand(@option(prefix="-h,--help", description="display help", isHelp=true) help:Boolean) {
@command(description="Say hello")
def hello(@option(prefix="-r", description="repeat times")
repeat:Int=1,
@argument
message:String = "hello") {
for(i <- 0 until repeat) println(message)
}
}
Launcher.execute[MyCommand]("hello -r 3") // hello x 3
Attributes
- Graph
-
- Supertypes
-
trait LogSupporttrait LazyLoggertrait LoggingMethodstrait Serializableclass Objecttrait Matchableclass Any
Members list
In this article