$this->requestStack =
$requestStack;
$this->dumper =
$dumper;
// All clones share these properties by reference:
$this->rootRefs =
[ &
$this->data,
&
$this->dataCount,
&
$this->isCollected,
&
$this->clonesCount,
];
$this->sourceContextProvider =
$dumper instanceof Connection &&
isset($dumper->
getContextProviders()['source'
]) ?
$dumper->
getContextProviders()['source'
] :
new SourceContextProvider($this->charset
);
} public function __clone() { $this->clonesIndex = ++
$this->clonesCount;
} public function dump(Data
$data): ?string
{ $this->stopwatch?->
start('dump'
);
[