All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.jwi.use.Comparators Maven / Gradle / Ivy

The newest version!
package org.jwi.use;

import java.util.Comparator;

public class Comparators
{
    public static final Comparator cmpLOUpperFirst = (s1, s2) -> {
        int c = s1.compareToIgnoreCase(s2);
        if (c != 0)
        {
            return c;
        }
        return s1.compareTo(s2);
    };

    public static final Comparator cmpLOLowerFirst = (s1, s2) -> {
        int c = s1.compareToIgnoreCase(s2);
        if (c != 0)
        {
            return c;
        }
        return -s1.compareTo(s2);
    };
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy