/** * Compare the names of two files with the specified case sensitivity. * * @param file1 The first file to compare * @param file2 The second file to compare * @return a negative value if the first file's name * is less than the second, zero if the names are the * same and a positive value if the first files name * is greater than the second file. */ public int compare(File file1, File file2) { return caseSensitivity.checkCompareTo(file1.getName(), file2.getName()); }