• Full name: \App\Shared\Services\Hydrator
  • This class is marked as final and can't be subclassed
  • This class is a Final class

Properties

reflectionClassMap

private array $reflectionClassMap

Methods

hydrate

public hydrate(object|string $target, array $data): object

Parameters:

Parameter Type Description
$target object|string
$data array

Throws:


extract

public extract(object $object, array $fields): array

Parameters:

Parameter Type Description
$object object
$fields array

Throws:


getReflectionClass

private getReflectionClass(object|string $target): \ReflectionClass

Parameters:

Parameter Type Description
$target object|string

Throws: