You are here

public function Application::asText in Zircon Profile 8.0

Same name and namespace in other branches
  1. 8 vendor/symfony/console/Application.php \Symfony\Component\Console\Application::asText()

Returns a text representation of the Application.

Parameters

string $namespace An optional namespace name:

bool $raw Whether to return raw command list:

Return value

string A string representing the Application

Deprecated

since version 2.3, to be removed in 3.0.

File

vendor/symfony/console/Application.php, line 589

Class

Application
An Application is the container for a collection of commands.

Namespace

Symfony\Component\Console

Code

public function asText($namespace = null, $raw = false) {
  @trigger_error('The ' . __METHOD__ . ' method is deprecated since version 2.3 and will be removed in 3.0.', E_USER_DEPRECATED);
  $descriptor = new TextDescriptor();
  $output = new BufferedOutput(BufferedOutput::VERBOSITY_NORMAL, !$raw);
  $descriptor
    ->describe($output, $this, array(
    'namespace' => $namespace,
    'raw_output' => true,
  ));
  return $output
    ->fetch();
}