Exports a value into a single-line string
The output of this method is similar to the output of PHPUnit_Util_Type::export. This method guarantees thought that the result contains now newlines.
Newlines are replaced by the visible string '\n'. Contents of arrays and objects (if any) are replaced by '...'.
mixed $value The value to export:
integer $indentation The indentation level of the 2nd+ line:
string
PHPUnit_Util_Type::export
public static function shortenedExport($value) {
if (is_string($value)) {
return self::shortenedString($value);
}
if (is_object($value)) {
return sprintf('%s Object (%s)', get_class($value), count(self::toArray($value)) > 0 ? '...' : '');
}
if (is_array($value)) {
return sprintf('Array (%s)', count($value) > 0 ? '...' : '');
}
return self::export($value);
}