Package org.javlo.helper.Comparator
Class FileComparator
- java.lang.Object
-
- org.javlo.helper.Comparator.FileComparator
-
- All Implemented Interfaces:
Comparator<File>
public class FileComparator extends Object implements Comparator<File>
- Author:
- pvanderm This class is used for sort a array of File.
-
-
Field Summary
Fields Modifier and Type Field Description static int
LASTMODIFIED
static int
NAME
static int
SIZE
-
Constructor Summary
Constructors Constructor Description FileComparator(int inSortType, boolean inAscending)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compare(File file1, File file2)
compare two array of Comparable-
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
-
-
-
-
Field Detail
-
NAME
public static final int NAME
- See Also:
- Constant Field Values
-
LASTMODIFIED
public static final int LASTMODIFIED
- See Also:
- Constant Field Values
-
SIZE
public static final int SIZE
- See Also:
- Constant Field Values
-
-
Method Detail
-
compare
public int compare(File file1, File file2)
compare two array of Comparable- Specified by:
compare
in interfaceComparator<File>
-
-