original_string: public static function compare($version1, $version2, $operator, $precision = null)
      {
          $version1 = self::normalize($version1, $precision);
          $version2 = self::normalize($version2, $precision);
  
          return version_compare($version1, $version2, $operator);
      }
code: public static function compare($version1, $version2, $operator, $precision = null)
      {
          $version1 = self::normalize($version1, $precision);
          $version2 = self::normalize($version2, $precision);
  
          return version_compare($version1, $version2, $operator);
      }
code_tokens: public static function compare ( $ version1 , $ version2 , $ operator , $ precision = null ) { $ version1 = self :: normalize ( $ version1 , $ precision ) ; $ version2 = self :: normalize ( $ version2 , $ precision ) ; return version_compare ( $ version1 , $ version2 , $ operator ) ; }
docstring: Compares two versions with an operator.
  
  This method is identical to {@link version_compare()}, except that you
  can pass the number of regarded version components in the last argument
  $precision.
  
  Examples:
  
  Version::compare('1.2.3', '1.2.4', '==')
  // => false
  
  Version::compare('1.2.3', '1.2.4', '==', 2)
  // => true
  
  @param string   $version1  A version string
  @param string   $version2  A version string to compare
  @param string   $operator  The comparison operator
  @param int|null $precision The number of components to compare. Pass
  NULL to compare the versions unchanged.
  
  @return bool Whether the comparison succeeded
  
  @see normalize()
docstring_tokens: Compares two versions with an operator .