Package com.nt.udc.nar
Class NARFileComparator
java.lang.Object
com.nt.udc.nar.NARFileComparator
- All Implemented Interfaces:
FileComparator,Comparator
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
Constructor Details
-
NARFileComparator
-
-
Method Details
-
compareFiles
Compares 2 NAR files, based on their File names.- Specified by:
compareFilesin interfaceFileComparator- Parameters:
file1- First file namefile2- Second file name- Returns:
- -1, if file1 invalid input: '<' file2 0 , if file1 == file2 1 , if file1 > file2
- Throws:
FileParseException
-
compare
Compares 2 NAR file names, as described in compareFiles(x,y). If the FileParseException is caught, this method will return 0 to ensure no sorting is done.- Specified by:
comparein interfaceComparator
-