You are here

public function DevelDumperManager::export in Devel 8.2

Same name and namespace in other branches
  1. 8.3 src/DevelDumperManager.php \Drupal\devel\DevelDumperManager::export()
  2. 8 src/DevelDumperManager.php \Drupal\devel\DevelDumperManager::export()
  3. 4.x src/DevelDumperManager.php \Drupal\devel\DevelDumperManager::export()

Returns a string representation of a variable.

Parameters

mixed $input: The variable to dump.

string $name: (optional) The label to output before variable, defaults to NULL.

string $plugin_id: (optional) The plugin ID, defaults to NULL.

Return value

string String representation of a variable.

Overrides DevelDumperManagerInterface::export

1 call to DevelDumperManager::export()
DevelDumperManager::message in src/DevelDumperManager.php
Sets a message with a string representation of a variable.

File

src/DevelDumperManager.php, line 84

Class

DevelDumperManager
Class DevelDumperManager.

Namespace

Drupal\devel

Code

public function export($input, $name = NULL, $plugin_id = NULL) {
  if ($this
    ->hasAccessToDevelInformation()) {
    return $this
      ->createInstance($plugin_id)
      ->export($input, $name);
  }
  return NULL;
}