Neos\Flow\I18n\Parser\DatetimeParser::parseDate PHP Method

parseDate() public method

Parses date with format string for date defined in CLDR for particular locale.
public parseDate ( string $dateToParse, Locale $locale, string $formatLength = DatesReader::FORMAT_LENGTH_DEFAULT, boolean $strictMode = true ) : mixed
$dateToParse string date to be parsed
$locale Neos\Flow\I18n\Locale
$formatLength string One of: full, long, medium, short, or 'default' in order to use default length from CLDR
$strictMode boolean Work mode (strict when TRUE, lenient when FALSE)
return mixed Array of parsed date elements, FALSE on failure
    public function parseDate($dateToParse, I18n\Locale $locale, $formatLength = DatesReader::FORMAT_LENGTH_DEFAULT, $strictMode = true)
    {
        DatesReader::validateFormatLength($formatLength);
        return $this->doParsingWithParsedFormat($dateToParse, $this->datesReader->parseFormatFromCldr($locale, DatesReader::FORMAT_TYPE_DATE, $formatLength), $this->datesReader->getLocalizedLiteralsForLocale($locale), $strictMode);
    }