class DateTimeToTimestampTransformer extends BaseDateTimeTransformer
Transforms between a timestamp and a DateTime object.
Methods
__construct(string $inputTimezone = null, string $outputTimezone = null) Constructor. | from BaseDateTimeTransformer | |
mixed | transform(DateTimeInterface $dateTime) Transforms a DateTime object into a timestamp in the configured timezone. | |
mixed | reverseTransform(mixed $value) Transforms a timestamp in the configured timezone into a DateTime object. |
Details
__construct(string $inputTimezone = null, string $outputTimezone = null)
Constructor.
mixed transform(DateTimeInterface $dateTime)
Transforms a DateTime object into a timestamp in the configured timezone.
mixed reverseTransform(mixed $value)
Transforms a timestamp in the configured timezone into a DateTime object.
Please login to continue.