original_string: public static function getClassDescription(string $class, string &$resolvedClass = null): string
      {
          $resolvedClass = $class;
          try {
              $resource = new ClassExistenceResource($class, false);
  
              // isFresh() will explode ONLY if a parent class/trait does not exist
              $resource->isFresh(0);
  
              $r = new \ReflectionClass($class);
              $resolvedClass = $r->name;
  
              if ($docComment = $r->getDocComment()) {
                  $docComment = preg_split('#\n\s*\*\s*[\n@]#', substr($docComment, 3, -2), 2)[0];
  
                  return trim(preg_replace('#\s*\n\s*\*\s*#', ' ', $docComment));
              }
          } catch (\ReflectionException $e) {
          }
  
          return '';
      }
code: public static function getClassDescription(string $class, string &$resolvedClass = null): string
      {
          $resolvedClass = $class;
          try {
              $resource = new ClassExistenceResource($class, false);
  
              // isFresh() will explode ONLY if a parent class/trait does not exist
              $resource->isFresh(0);
  
              $r = new \ReflectionClass($class);
              $resolvedClass = $r->name;
  
              if ($docComment = $r->getDocComment()) {
                  $docComment = preg_split('#\n\s*\*\s*[\n@]#', substr($docComment, 3, -2), 2)[0];
  
                  return trim(preg_replace('#\s*\n\s*\*\s*#', ' ', $docComment));
              }
          } catch (\ReflectionException $e) {
          }
  
          return '';
      }
code_tokens: public static function getClassDescription ( string $ class , string & $ resolvedClass = null ) : string { $ resolvedClass = $ class ; try { $ resource = new ClassExistenceResource ( $ class , false ) ; // isFresh() will explode ONLY if a parent class/trait does not exist $ resource -> isFresh ( 0 ) ; $ r = new \ ReflectionClass ( $ class ) ; $ resolvedClass = $ r -> name ; if ( $ docComment = $ r -> getDocComment ( ) ) { $ docComment = preg_split ( '#\n\s*\*\s*[\n@]#' , substr ( $ docComment , 3 , - 2 ) , 2 ) [ 0 ] ; return trim ( preg_replace ( '#\s*\n\s*\*\s*#' , ' ' , $ docComment ) ) ; } } catch ( \ ReflectionException $ e ) { } return '' ; }
docstring: Gets class description from a docblock.
docstring_tokens: Gets class description from a docblock .