public void setMinDiff(double minDiff) {
        if (minDiff < 0.0) {
            throw new IllegalArgumentException("minDiff must be >= 0.0");
        }
        this.minDiff = minDiff;
    }
The minimum difference between the highest confidence and the
second highest confidence required to stop.
<p>
Throws {@link IllegalArgumentException} if &lt; 0.0

@param minDiff
tika-langdetect/tika-langdetect-opennlp/src/main/java/org/apache/tika/langdetect/opennlp/ProbingLanguageDetector.java