Package studentrepoloader.filesystem
package studentrepoloader.filesystem
Provides infrastructure for organizing and preparing local directories for Git-based student submissions.
This package defines:
- The
SubmissionPathPlanner
interface, which models strategies for mappingVilleSubmissionFields
instances to unique localPath
s under a shared root directory. - Concrete planners such as:
FlatSubmissionPathPlanner
— places all submissions into a single flat directoryRangeSubmissionPathPlanner
— groups submissions under a directory named by the lexicographic ID range
- The utility class
DirectoryUtils
, which provides file system helpers used throughout the cloning and logging infrastructure, such as:- Safe creation of directories and log files
- Log file writing with configurable append behavior
- Detection of previously cloned repositories via presence of
.git/
All path planner strategies return immutable Map<Submission, Path>
objects and guarantee that
no duplicate paths are emitted. Runtime path collisions will trigger explicit exceptions.
This package is consumed primarily by SubmissionCloner
and invoked from
entry points like Launcher
.
-
ClassDescriptionUtility methods for managing directory and log file creation.FlatSubmissionPathPlanner<S extends VilleSubmissionFields>Strategy that puts all submissions into a single flat directory directly under the root.RangeSubmissionPathPlanner<S extends VilleSubmissionFields>Strategy that groups submissions under a directory named by the submission file and ID range.SubmissionPathPlanner<S extends VilleSubmissionFields>Strategy interface for planning directory paths for a list of submissions.Extracts the static template directory structure used by ViLLe RepoLoader.