code: protected function getReturnType(array $lines)
      {
          foreach ($lines as $line) {
              if (strpos($line, '@return') === 0) {
                  $type = trim(str_replace('@return', '', $line));
                  $type = str_replace('$this', 'self', $type);
                  $type = explode('|', $type);
                  return $type;
              }
          }
          return [];
      }
docs: Gets the return types from a method or function's comment.
  
  This method will always return an array to allow for the possibility of
  multiple return types split with | pipe. It will also replace '$this'
  with 'self' to (somewhat) hide internals.
  
  @param array $lines
  @return string[]