Package org.machanism.machai.project
ProjectLayoutManager identifies a
project from its build or package descriptor and configures the corresponding
ProjectLayout. The supported
descriptors are checked in this order: Maven (pom.xml), Gradle
(build.gradle), JavaScript or TypeScript (package.json), and
Python (pyproject.toml). Existing directories without a recognized
descriptor use DefaultProjectLayout; a missing directory causes
FileNotFoundException.
ProjectProcessor uses the selected
layout to process either the current project or each reported child module.
Subclasses implement
ProjectProcessor.processFolder(org.machanism.machai.project.layout.ProjectLayout)
and can use the layout's root-relative source, test, and documentation paths
to perform repository-specific work. A layout may return null for
modules when it is not a parent project.
Typical usage
java.io.File projectDir = new java.io.File("path/to/project");
org.machanism.machai.project.ProjectProcessor processor = ...;
processor.scanFolder(projectDir);
Implementations should make folder processing safe to invoke once for
every discovered project or module. See the
org.machanism.machai.project.layout package for the concrete layout
implementations and their metadata-specific behavior.
- Since:
- 0.0.2
-
ClassesClassDescriptionManages detection and instantiation of specific
ProjectLayoutimplementations based on the structure of a given project directory.Abstract base class for processing project structures and modules.