ProgramArgs.on

Calls handler if user specified command subcommand.

class ProgramArgs
typeof(this)
on
(
string command
,
scope void delegate() handler
)

Examples

1 auto a = new Program()
2     .add(new Command("test"))
3     .parse(args);
4 
5 a.on("test", (a) {
6    writeln("Test!");
7 });

Meta