src/CommandFactory/CommandFactoryTrait.php
protected function getCommand(StrategyInterface $strategy)
    {
        $command = $strategy->get();
        if ($command === null) {
            throw new Exception('Failed to locate a sensible command');
        }

        return $command;
    }
protected function getCommand(StrategyInterface $strategy)
    {
        $command = $strategy->get();
        if ($command === null) {
            throw new Exception('Failed to locate a sensible command');
        }

        return $command;
    }
protected function getCommand ( StrategyInterface $ strategy ) { $ command = $ strategy -> get ( ) ; if ( $ command === null ) { throw new Exception ( 'Failed to locate a sensible command' ) ; } return $ command ; }
Execute the strategy and return the command.

@param \Nubs\Sensible\Strategy\StrategyInterface $strategy The strategy
to locate a command with.
@return string The command to execute.
@throws \Exception if the strategy fails to find a command.
Execute the strategy and return the command .