com.enderak.procol.common.util
Class ProColFileComparator

java.lang.Object
  |
  +--com.enderak.procol.common.util.ProColFileComparator
All Implemented Interfaces:
java.util.Comparator

public class ProColFileComparator
extends java.lang.Object
implements java.util.Comparator

ProColFileComparator compares two ProCol files for sorting purposes

Author:
Justin Dieters

Constructor Summary
ProColFileComparator()
           
 
Method Summary
 int compare(java.lang.Object o1, java.lang.Object o2)
          Compare two ProColFiles
 boolean equals(java.lang.Object obj)
          required by Comparator interface, just compares this Compator to the input object
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProColFileComparator

public ProColFileComparator()
Method Detail

compare

public int compare(java.lang.Object o1,
                   java.lang.Object o2)
Compare two ProColFiles

Specified by:
compare in interface java.util.Comparator
Parameters:
o1 - File 1
o2 - File 2
Returns:
1 if o1 is a file and o2 is a Directory, -1 if o1 is a directory and o2 is a file, or the output of comparing the names of the files as lowercase strings (i.e. not case-sensitive)

equals

public boolean equals(java.lang.Object obj)
required by Comparator interface, just compares this Compator to the input object

Specified by:
equals in interface java.util.Comparator
Overrides:
equals in class java.lang.Object
Parameters:
obj - the object to test
Returns:
True if equal, false otherwise