class DateTimeToTimestampTransformer extends BaseDateTimeTransformer
Transforms between a timestamp and a DateTime object
__construct(string $inputTimezone = null, string $outputTimezone = null) Constructor. | from BaseDateTimeTransformer | |
int | transform(DateTime $value) Transforms a DateTime object into a timestamp in the configured timezone. | |
DateTime | reverseTransform(string $value) Transforms a timestamp in the configured timezone into a DateTime object |
Constructor.
Transforms a DateTime object into a timestamp in the configured timezone.
Transforms a timestamp in the configured timezone into a DateTime object
© 2004–2016 Fabien Potencier
Licensed under the MIT License.
http://api.symfony.com/2.7/Symfony/Component/Form/Extension/Core/DataTransformer/DateTimeToTimestampTransformer.html