original_string: public function execute(Arguments $args, ConsoleIo $io)
      {
          if (!$args->getOption('xml')) {
              $io->out('<info>Current Paths:</info>', 2);
              $io->out('* app:  ' . APP_DIR . DIRECTORY_SEPARATOR);
              $io->out('* root: ' . ROOT . DIRECTORY_SEPARATOR);
              $io->out('* core: ' . CORE_PATH);
              $io->out('');
  
              $io->out('<info>Available Commands:</info>', 2);
          }
  
          $commands = $this->commands->getIterator();
          $commands->ksort();
  
          if ($args->getOption('xml')) {
              $this->asXml($io, $commands);
  
              return static::CODE_SUCCESS;
          }
          $this->asText($io, $commands);
  
          return static::CODE_SUCCESS;
      }
code: public function execute(Arguments $args, ConsoleIo $io)
      {
          if (!$args->getOption('xml')) {
              $io->out('<info>Current Paths:</info>', 2);
              $io->out('* app:  ' . APP_DIR . DIRECTORY_SEPARATOR);
              $io->out('* root: ' . ROOT . DIRECTORY_SEPARATOR);
              $io->out('* core: ' . CORE_PATH);
              $io->out('');
  
              $io->out('<info>Available Commands:</info>', 2);
          }
  
          $commands = $this->commands->getIterator();
          $commands->ksort();
  
          if ($args->getOption('xml')) {
              $this->asXml($io, $commands);
  
              return static::CODE_SUCCESS;
          }
          $this->asText($io, $commands);
  
          return static::CODE_SUCCESS;
      }
code_tokens: public function execute ( Arguments $ args , ConsoleIo $ io ) { if ( ! $ args -> getOption ( 'xml' ) ) { $ io -> out ( '<info>Current Paths:</info>' , 2 ) ; $ io -> out ( '* app:  ' . APP_DIR . DIRECTORY_SEPARATOR ) ; $ io -> out ( '* root: ' . ROOT . DIRECTORY_SEPARATOR ) ; $ io -> out ( '* core: ' . CORE_PATH ) ; $ io -> out ( '' ) ; $ io -> out ( '<info>Available Commands:</info>' , 2 ) ; } $ commands = $ this -> commands -> getIterator ( ) ; $ commands -> ksort ( ) ; if ( $ args -> getOption ( 'xml' ) ) { $ this -> asXml ( $ io , $ commands ) ; return static :: CODE_SUCCESS ; } $ this -> asText ( $ io , $ commands ) ; return static :: CODE_SUCCESS ; }
docstring: Main function Prints out the list of commands.
  
  @param \Cake\Console\Arguments $args The command arguments.
  @param \Cake\Console\ConsoleIo $io The console io
  @return int
docstring_tokens: Main function Prints out the list of commands .