Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. DumpDataCollector.php

function DumpDataCollector::__wakeup

@internal

Overrides DataCollector::__wakeup

File

vendor/symfony/http-kernel/DataCollector/DumpDataCollector.php, line 170

Class

DumpDataCollector
@author Nicolas Grekas <p@tchwork.com>

Namespace

Symfony\Component\HttpKernel\DataCollector

Code

public function __wakeup() : void {
    parent::__wakeup();
    $charset = array_pop($this->data);
    $fileLinkFormat = array_pop($this->data);
    $this->dataCount = \count($this->data);
    foreach ($this->data as $dump) {
        if (!\is_string($dump['name']) || !\is_string($dump['file']) || !\is_int($dump['line'])) {
            throw new \BadMethodCallException('Cannot unserialize ' . __CLASS__);
        }
    }
    self::__construct($this->stopwatch ?? null, \is_string($fileLinkFormat) || $fileLinkFormat instanceof FileLinkFormatter ? $fileLinkFormat : null, \is_string($charset) ? $charset : null);
}
RSS feed
Powered by Drupal