DateComparator.java [src/java/cfa] Revision: fcf11f0c1596fb75f89a7b8d50a56da357331ffc  Date: Fri Feb 05 16:38:37 MST 2016
package cfa;

import java.util.Comparator;

/**
* Last Updated: 4-February-2016
* @author Tyler Wible
* @since 4-February-2016
*/
public class DateComparator implements Comparator<String[]>{
    //Compares the first entry of sorted data as flow values and sorts largest to smallest
    public int compare(final String[] entry1, final String[] entry2) {
        String value1 = entry1[0];
        String value2 = entry2[0];
        int comparison = value1.compareTo(value2);
        if(comparison>0){
            return 1;
        }else if(comparison<0){
            return -1;
        }else{
            return 0;
        }
    }
}