original_string: public static function stringTrim(string $string, int $length): string
      {
          if ($length<16) return $string;
          if (strlen($string)>$length) {
              $str_head = substr($string, 0, $length-10);
              $str_tail = substr($string, -7, 7);
              return $str_head.'...'.$str_tail;
          }
          return $string;
      }
code: public static function stringTrim(string $string, int $length): string
      {
          if ($length<16) return $string;
          if (strlen($string)>$length) {
              $str_head = substr($string, 0, $length-10);
              $str_tail = substr($string, -7, 7);
              return $str_head.'...'.$str_tail;
          }
          return $string;
      }
code_tokens: public static function stringTrim ( string $ string , int $ length ) : string { if ( $ length < 16 ) return $ string ; if ( strlen ( $ string ) > $ length ) { $ str_head = substr ( $ string , 0 , $ length - 10 ) ; $ str_tail = substr ( $ string , - 7 , 7 ) ; return $ str_head . '...' . $ str_tail ; } return $ string ; }
docstring: Helper function to make a non-unicode string shortter
  
  @param string $string The string to be trimmed
  @param int    $length The targeted trimed length
  
  @return string trimmed string
docstring_tokens: Helper function to make a non - unicode string shortter