for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Graze\CiffRenderer\Parser\FieldParser\FieldParserDate\DateFormatter;
use Graze\CiffRenderer\Parser\FieldParser\FieldParserDate\DateFormatter\DateFormatterInterface;
use Urbanplum\DotnetDateTime\DotnetDateTime;
class DateFormatterBasic implements DateFormatterInterface
{
/**
* @param \DateTimeInterface $date
* @param string $format
* @return string
*/
public function format(\DateTimeInterface $date, $format)
$dotnetDateTime = new DotnetDateTime();
$phpFormat = $dotnetDateTime->formatToPhp($format);
return (string) $date->format($phpFormat);
}