src/View/Helper/DateFormat.php
protected function detectType($type)
    {
        $type     = strtoupper($type);
        $constant = "\IntlDateFormatter::$type";
        $value    = @constant($constant);
        return null !== $value ? $value : IntlDateFormatter::NONE;
    }
protected function detectType($type)
    {
        $type     = strtoupper($type);
        $constant = "\IntlDateFormatter::$type";
        $value    = @constant($constant);
        return null !== $value ? $value : IntlDateFormatter::NONE;
    }
Maps strings and constants to IntlDateFormatter constants (int).

@param string $type
@return int