src/Application.php
public function registerCommands(array $commands, callable $handler)
    {
        foreach ($commands as $command) {
            $handler_id = "app.handler." . join('', array_slice(explode("\\", $command), -1));
            $this[$handler_id] = $handler;
        }
    }
public function registerCommands(array $commands, callable $handler)
    {
        foreach ($commands as $command) {
            $handler_id = "app.handler." . join('', array_slice(explode("\\", $command), -1));
            $this[$handler_id] = $handler;
        }
    }
public function registerCommands ( array $ commands , callable $ handler ) { foreach ( $ commands as $ command ) { $ handler_id = "app.handler." . join ( '' , array_slice ( explode ( "\\" , $ command ) , - 1 ) ) ; $ this [ $ handler_id ] = $ handler ; } }
register command for our application
@param array $commands
@param callable $handler
register command for our application