Convert the minor version of date.

@param string $minor The minor version

@return string
482866
protected static function convertDateMinorVersion($minor)
    {
        $split = explode('.', $minor);
        $minor = (int) $split[0];
        $revision = isset($split[1]) ? (int) $split[1] : 0;

        return '.'.sprintf('%03d', $minor).sprintf('%03d', $revision);
    }
833225
public function ceil($prec = 0)
  {
    $dst = clone $this;
    $dst->value = $this->_ceil($this->value, $prec);
    return $dst;
  }
738282
public static function toVersion($version)
    {
        $components = self::toComponents($version);

        return new Version(
            $components['major'],
            $components['minor'],
            $components['patch'],
            $components['pre'],
            $components['build']
        );
    }
1356920
protected function convertVersionStatus($statusString)
    {
        switch (strtoupper($statusString)) {
            case 'PUBLISHED':
                return Values\Content\VersionInfo::STATUS_PUBLISHED;
            case 'DRAFT':
                return Values\Content\VersionInfo::STATUS_DRAFT;
            case 'ARCHIVED':
                return Values\Content\VersionInfo::STATUS_ARCHIVED;
        }
        throw new \RuntimeException(
            sprintf('Unknown version status: "%s"', $statusString)
        );
    }
843433
public function normalize($value)
    {
        if ($value) {
            if (is_int($value) || ctype_digit($value)) {
                $timestamp = $value;
            } elseif (!$timestamp = strtotime($value)) {
                return $value;
            }
            return date($this->_format, $timestamp);
        }
        return $value;
    }
207192
public function getDateFormat()
	{
		$date = strftime("%x", mktime(0, 0, 0, 1, 31, 2009));
		if (preg_match("/31[- \/.]0?1[- \/.](20)?09/", $date))
		{
			return DATEFORMAT::DMY;
		}
		elseif (preg_match("/0?1[- \/.]31[- \/.](20)?09/", $date))
		{
			return DATEFORMAT::MDY;
		}
		else
		{
			return DATEFORMAT::YMD;
		}
	}
734362
public static function majorVersion($version)
    {
        $components = explode('.', $version);
        foreach ($components as $key => $value) {
            if ($key > 0 && is_numeric($value)) {
                $components[$key] = '0';
            }
        }

        return implode('.', $components);
    }
704041
public static function dateFromUsFormat($value) {
        $temp = explode(' ', $value);
        $temp2 = array_reverse(explode('-', $temp[0]));
        return $temp2[0] . '/' . $temp2[1] . '/' . $temp2[2] . (isset($temp[1]) ? ' à ' . $temp[1] : '');
    }
311769
public static function getVersion (string $option = 'FULL') : string
    {
        if ($option === 'MAJOR') :
            $version = explode('.', self::VERSION);
            return $version[0].'.'.$version[1];
        else :
            return self::VERSION;
        endif;
    }
955160
public static function prettySeconds( $seconds = 0.0 )
    {
        $_remain = $seconds;
        $_hours = floor( $_remain / Enums\DateTime::SecondsPerHour );
        $_remain -= $_hours * Enums\DateTime::SecondsPerHour;

        $_minutes = floor( $_remain / Enums\DateTime::SecondsPerMinute );
        $_remain -= $_minutes * Enums\DateTime::SecondsPerMinute;

        return $_hours . 'h ' . $_minutes . 'm ' . number_format( $_remain, 2 ) . 's';
    }
618283
public function bySeconds(int $seconds): Date
    {
        return $this->secondTo($this->originalDate->seconds() + $seconds);
    }
849728
public function min($date = null)
    {
        $date = $this->resolveCarbon($date);

        return $this->lt($date) ? $this : $date;
    }
1209428
public static function Seconds($Seconds) {
      if (!is_numeric($Seconds)) {
         $Seconds = abs(time() - self::ToTimestamp($Seconds));
      }

      $Minutes = round($Seconds/60);
      $Hours = round($Seconds/3600);
      $Days = round($Seconds/86400);
      $Weeks = round($Seconds/604800);
      $Months = round($Seconds/2629743.83);
      $Years = round($Seconds/31556926);

      if ($Seconds < 60)
         return sprintf(Plural($Seconds, '%s second', '%s seconds'), $Seconds);
      elseif ($Minutes < 60)
         return sprintf(Plural($Minutes, '%s minute', '%s minutes'), $Minutes);
      elseif ($Hours < 24)
         return sprintf(Plural($Hours, '%s hour', '%s hours'), $Hours);
      elseif ($Days < 7)
         return sprintf(Plural($Days, '%s day', '%s days'), $Days);
      elseif ($Weeks < 4)
         return sprintf(Plural($Weeks, '%s week', '%s weeks'), $Weeks);
      elseif ($Months < 12)
         return sprintf(Plural($Months, '%s month', '%s months'), $Months);
      else
         return sprintf(Plural($Years, '%s year', '%s years'), $Years);
   }
757478
private static function formatVersion($version)
    {
        $version = str_replace(array('x', 'X', '*'), '0', $version);
        $exp = explode('.', $version);

        if (($size = \count($exp)) < 3) {
            for ($i = $size; $i < 3; ++$i) {
                $exp[] = '0';
            }
        }

        return $exp[0].'.'.$exp[1].'.'.$exp[2];
    }
905696
public function setMin(string $min) : Datetime
    {
        $min = date($this->format, strtotime($min));
        $this->attributes['min'] = $min;
        return $this->addTest('min', function ($value) use ($min) {
            return $value >= $min;
        });
    }
1316742
public function resolveScriptVersion($filename, $minified = false)
    {
        list($name, $extension) = str_split($filename, strrpos($filename, '.') + 1);
        return !$minified ? $name . $extension : $name . 'min.' . $extension;
    }
88899
public static function normalizeEta($eta)
    {
        if (null === $eta) {
            return time();
        }
        if (is_string($eta)) {
            $eta = date_create($eta);
        }
        if ($eta instanceof \DateTime || $eta instanceof \DateTimeInterface) {
            return $eta->getTimestamp();
        }
        if (is_int($eta)) {
            return $eta;
        }

        throw new \InvalidArgumentException('The eta parameter is not valid.');
    }