0 follower

Final Class Yiisoft\Hydrator\Attribute\Parameter\ToDateTime

InheritanceYiisoft\Hydrator\Attribute\Parameter\ToDateTime
ImplementsYiisoft\Hydrator\Attribute\Parameter\ParameterAttributeInterface

Converts the resolved value to DateTimeImmutable object. Non-resolved and invalid values are skipped.

Property Details

Hide inherited properties

$dateType public property
public ?int $dateType null
$format public property
public ?string $format null
$locale public property
public ?string $locale null
$timeType public property
public ?int $timeType null
$timeZone public property
public ?string $timeZone null

Method Details

Hide inherited methods

__construct() public method

public mixed __construct ( ?string $format null, ?int $dateType null, ?int $timeType null, ?string $timeZone null, ?string $locale null )
$format ?string
$dateType ?int
$timeType ?int
$timeZone ?string
$locale ?string

                public function __construct(
    public readonly ?string $format = null,
    public readonly ?int $dateType = null,
    public readonly ?int $timeType = null,
    public readonly ?string $timeZone = null,
    public readonly ?string $locale = null,
) {}

            
getResolver() public method

public string getResolver ( )

                public function getResolver(): string
{
    return ToDateTimeResolver::class;
}