Prevention comparator null pointer exception util
public Final class ComparatorUtil { Private ComparatorUtil () { the throw new new AssertionError with ( "Util prohibiting reflection instantiated" ); } public static <T> int the compareTo (the Comparable <T> C1, T C2) { return c1 == null || c2 == null 0? : c1.compareTo (c2); } }