Symfony\Component\VarDumper\Caster\ExceptionCaster::castThrowingCasterException PHP Method

castThrowingCasterException() public static method

public static castThrowingCasterException ( Symfony\Component\VarDumper\Exception\ThrowingCasterException $e, array $a, Symfony\Component\VarDumper\Cloner\Stub $stub, $isNested )
$e Symfony\Component\VarDumper\Exception\ThrowingCasterException
$a array
$stub Symfony\Component\VarDumper\Cloner\Stub
    public static function castThrowingCasterException(ThrowingCasterException $e, array $a, Stub $stub, $isNested)
    {
        $prefix = Caster::PREFIX_PROTECTED;
        $xPrefix = "Exception";
        if (isset($a[$xPrefix . 'previous'], $a[$xPrefix . 'trace'])) {
            $b = (array) $a[$xPrefix . 'previous'];
            self::traceUnshift($b[$xPrefix . 'trace'], get_class($a[$xPrefix . 'previous']), $b[$prefix . 'file'], $b[$prefix . 'line']);
            $a[$xPrefix . 'trace'] = new TraceStub($b[$xPrefix . 'trace'], false, 0, -1 - count($a[$xPrefix . 'trace']->value));
        }
        unset($a[$xPrefix . 'previous'], $a[$prefix . 'code'], $a[$prefix . 'file'], $a[$prefix . 'line']);
        return $a;
    }