On this page
Class DebugContext
Context tracking for Debugger::exportVar()
This class is used by Debugger to track element depth, and prevent cyclic references from being traversed multiple times.
Method Summary
__construct() public
Constructor
getReferenceId() public
Get the reference ID for an object.
hasReference() public
Check whether an object has been seen before.
remainingDepth() public
Get the remaining depth levels
withAddedDepth() public
Return a clone with increased depth.
Method Detail
__construct() public
__construct(int $maxDepth)
Constructor
Parameters
int$maxDepth-
The desired depth of dump output.
getReferenceId() public
getReferenceId(object $object): int
Get the reference ID for an object.
If this object does not exist in the reference storage, it will be added and the id will be returned.
Parameters
object$object-
The object to get a reference for.
Returns
inthasReference() public
hasReference(object $object): bool
Check whether an object has been seen before.
Parameters
object$object-
The object to get a reference for.
Returns
boolremainingDepth() public
remainingDepth(): int
Get the remaining depth levels
Returns
intwithAddedDepth() public
withAddedDepth(): static
Return a clone with increased depth.
Returns
static© 2005–present The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
https://api.cakephp.org/4.4/class-Cake.Error.Debug.DebugContext.html