Example #1
0
 /** Test that comparator is defined. */
 public static void testGetComparator() throws Exception {
   assert (WritableComparator.get(Frob.class) instanceof FrobComparator);
 }
Example #2
0
 static { // register this comparator
   WritableComparator.define(NullWritable.class, new Comparator());
 }
Example #3
0
 static { // register default comparator
   WritableComparator.define(Frob.class, new FrobComparator());
 }