private function storeDebug(CommandInterface $command, $direction) { $firtsArg = $command->getArgument(0); $timestamp = round(microtime(true) - $this->tstart, 4); $debug = $command->getId(); $debug .= isset($firtsArg) ? " {$firtsArg} " : ' '; $debug .= "{$direction} {$this}"; $debug .= " [{$timestamp}s]"; $this->debugBuffer[] = $debug; }
/** * Extracts the key from the first argument of a command instance. * * @param CommandInterface $command Command instance. * @return string */ protected function getKeyFromFirstArgument(CommandInterface $command) { return $command->getArgument(0); }