code: public function getProjectSearchPaths(string $name): array {
          $srcPaths = $this->getProject()->getAttribute(AttributeInterface::SEARCH_PATHS_ATTR_NAME);
          if($srcPaths instanceof SearchPathCollection) {
              return $srcPaths->getSearchPaths($name) ?? [];
          }
          return [];
      }
docs: Obtaining search paths from project
  
  @param string $name
  @return array