|
@@ -12,21 +12,6 @@ public class JPlagOptions {
|
|
|
*/
|
|
*/
|
|
|
private Language language;
|
|
private Language language;
|
|
|
|
|
|
|
|
- /**
|
|
|
|
|
- * Deprecated - use similarityThreshold instead! Maximum number of comparisons to store per run.
|
|
|
|
|
- */
|
|
|
|
|
- @Deprecated
|
|
|
|
|
- private int storeMatches = 30;
|
|
|
|
|
-
|
|
|
|
|
- /**
|
|
|
|
|
- * Deprecated - use similarityThreshold instead!
|
|
|
|
|
- * <p>
|
|
|
|
|
- * True, if `storeMatches` should be interpreted as a percentage threshold for the similarity of a comparison; false
|
|
|
|
|
- * otherwise;
|
|
|
|
|
- */
|
|
|
|
|
- @Deprecated
|
|
|
|
|
- private boolean storePercent = false;
|
|
|
|
|
-
|
|
|
|
|
/**
|
|
/**
|
|
|
* TODO PB: Decide what to do with this.
|
|
* TODO PB: Decide what to do with this.
|
|
|
* <p>
|
|
* <p>
|
|
@@ -59,6 +44,12 @@ public class JPlagOptions {
|
|
|
*/
|
|
*/
|
|
|
private float similarityThreshold = 0;
|
|
private float similarityThreshold = 0;
|
|
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
|
+ * The maximum number of matches that will be saved. This does affect the generated report as well as the internally
|
|
|
|
|
+ * saved comparisons. If set to -1 all matches will be saved.
|
|
|
|
|
+ */
|
|
|
|
|
+ private int maxNumberOfMatches = 30;
|
|
|
|
|
+
|
|
|
/**
|
|
/**
|
|
|
* TODO PB: Not happy with the name yet.
|
|
* TODO PB: Not happy with the name yet.
|
|
|
*/
|
|
*/
|
|
@@ -151,16 +142,6 @@ public class JPlagOptions {
|
|
|
return fileSuffixes;
|
|
return fileSuffixes;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- @Deprecated
|
|
|
|
|
- public int getStoreMatches() {
|
|
|
|
|
- return storeMatches;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- @Deprecated
|
|
|
|
|
- public boolean isStorePercent() {
|
|
|
|
|
- return storePercent;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
public Language getLanguage() {
|
|
public Language getLanguage() {
|
|
|
return language;
|
|
return language;
|
|
|
}
|
|
}
|
|
@@ -197,6 +178,10 @@ public class JPlagOptions {
|
|
|
return similarityThreshold;
|
|
return similarityThreshold;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ public int getMaxNumberOfMatches() {
|
|
|
|
|
+ return this.maxNumberOfMatches;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
public SimilarityMetric getSimilarityMetric() {
|
|
public SimilarityMetric getSimilarityMetric() {
|
|
|
return similarityMetric;
|
|
return similarityMetric;
|
|
|
}
|
|
}
|
|
@@ -221,16 +206,6 @@ public class JPlagOptions {
|
|
|
this.fileSuffixes = fileSuffixes;
|
|
this.fileSuffixes = fileSuffixes;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- @Deprecated
|
|
|
|
|
- public void setStoreMatches(int storeMatches) {
|
|
|
|
|
- this.storeMatches = storeMatches;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- @Deprecated
|
|
|
|
|
- public void setStorePercent(boolean storePercent) {
|
|
|
|
|
- this.storePercent = storePercent;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
public void setMinTokenMatch(Integer minTokenMatch) {
|
|
public void setMinTokenMatch(Integer minTokenMatch) {
|
|
|
this.minTokenMatch = minTokenMatch;
|
|
this.minTokenMatch = minTokenMatch;
|
|
|
}
|
|
}
|
|
@@ -269,6 +244,14 @@ public class JPlagOptions {
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ public void setMaxNumberOfMatches(int maxNumberOfMatches) {
|
|
|
|
|
+ if(maxNumberOfMatches < -1) {
|
|
|
|
|
+ this.maxNumberOfMatches = -1;
|
|
|
|
|
+ } else {
|
|
|
|
|
+ this.maxNumberOfMatches = maxNumberOfMatches;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
public void setSimilarityMetric(SimilarityMetric similarityMetric) {
|
|
public void setSimilarityMetric(SimilarityMetric similarityMetric) {
|
|
|
this.similarityMetric = similarityMetric;
|
|
this.similarityMetric = similarityMetric;
|
|
|
}
|
|
}
|