[ Index ]

PHP Cross Reference of Joomla 4.2.2 documentation

title

Body

[close]

/libraries/vendor/symfony/var-dumper/Cloner/ -> AbstractCloner.php (summary)

AbstractCloner implements a generic caster mechanism for objects and resources.

Author: Nicolas Grekas <[email protected]>
File Size: 400 lines (21 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 8 functions

  __construct()
  addCasters()
  setMaxItems()
  setMaxString()
  setMinDepth()
  cloneVar()
  castObject()
  castResource()

Functions
Functions that are not part of a class:

__construct(array $casters = null)   X-Ref

param: callable[]|null $casters A map of casters

addCasters(array $casters)   X-Ref
Adds casters for resources and objects.

Maps resources or objects types to a callback.
Types are in the key, with a callable caster for value.
Resource types are to be prefixed with a `:`,
see e.g. static::$defaultCasters.

param: callable[] $casters A map of casters

setMaxItems(int $maxItems)   X-Ref
Sets the maximum number of items to clone past the minimum depth in nested structures.


setMaxString(int $maxString)   X-Ref
Sets the maximum cloned length for strings.


setMinDepth(int $minDepth)   X-Ref
Sets the minimum tree depth where we are guaranteed to clone all the items.  After this
depth is reached, only setMaxItems items will be cloned.


cloneVar($var, int $filter = 0)   X-Ref
Clones a PHP variable.

param: mixed $var    Any PHP variable
param: int   $filter A bit field of Caster::EXCLUDE_* constants
return: Data

castObject(Stub $stub, bool $isNested)   X-Ref
Casts an object to an array representation.

param: bool $isNested True if the object is nested in the dumped structure
return: array

castResource(Stub $stub, bool $isNested)   X-Ref
Casts a resource to an array representation.

param: bool $isNested True if the object is nested in the dumped structure
return: array



Generated: Wed Sep 7 05:41:13 2022 Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer