SourceRootFinder
io.joern.javasrc2cpg.util.SourceRootFinder
object SourceRootFinder
Given a codeDirectory
, the SourceRootFinder attempts to find all the source roots (so that the subdirectories match the package structure of the source files). The JavaParserTypeSolver is path-dependent, so without this the user would need to ensure that they specify the correct source directory when running javasrc2cpg.
This works by checking if any subdirectories of the given directory match common java directory structures. In order of preference: * Maven's default structure, e.g. src/main/java/io/... and src/test/java/io/... * Top-level src and test directories, e.g. src/io/... and test/io/... If neither of these match, then it defaults to using the given user input as the source root.
Attributes
- Graph
-
- Supertypes
-
class Objecttrait Matchableclass Any
- Self type
-
SourceRootFinder.type
Members list
In this article