Class FileNameComparator
- java.lang.Object
-
- com.sun.identity.shared.test.tools.FileNameComparator
-
- All Implemented Interfaces:
Comparator<File>
public class FileNameComparator extends Object implements Comparator<File>
Comparator to order test case.
-
-
Constructor Summary
Constructors Constructor Description FileNameComparator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(File f1, File f2)
Returns 0 iff1.getPath()
equalsf2.getPath()
; 1 iff1.getPath()
is greater thanf2.getPath()
; and -1 iff1.getPath()
is smaller thanf2.getPath()
;-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
-
-
-
-
Method Detail
-
compare
public int compare(File f1, File f2)
Returns 0 iff1.getPath()
equalsf2.getPath()
; 1 iff1.getPath()
is greater thanf2.getPath()
; and -1 iff1.getPath()
is smaller thanf2.getPath()
;- Specified by:
compare
in interfaceComparator<File>
- Parameters:
f1
- File #1.f2
- File #2.- Returns:
- the comparison of
f1
andf2
based on path name.
-
-