Skip to content

Commit f2935ec

Browse files
committed
convenience constructor for AnalysisRunner.Options
1 parent ea252bf commit f2935ec

1 file changed

Lines changed: 17 additions & 0 deletions

File tree

src/main/java/org/variantsync/diffdetective/AnalysisRunner.java

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,23 @@ public record Options(
5757
*/
5858
boolean pullRepositoriesBeforeAnalysis
5959
) {
60+
/**
61+
* Creates options with the given parameters and uses default
62+
* values for all other parameters.
63+
* @see Options#Options(Path, Path, Path, Function, Function, boolean, boolean)
64+
* @see Options#DEFAULT(String[])
65+
*/
66+
public Options(Path repositoriesDirectory,
67+
Path outputDirectory,
68+
Path datasetsFile) {
69+
this(
70+
repositoriesDirectory, outputDirectory, datasetsFile,
71+
Repository::getParseOptions,
72+
Repository::getDiffFilter,
73+
true,
74+
false);
75+
}
76+
6077
public static Options DEFAULT(final String[] args) {
6178
final Path datasetsFile;
6279
if (args.length < 1) {

0 commit comments

Comments
 (0)