samples.random
Class LexicographicComparator

java.lang.Object
  extended by samples.random.LexicographicComparator
All Implemented Interfaces:
Comparator<int[]>

public class LexicographicComparator
extends Object
implements Comparator<int[]>

A comparator that allows to put arrays of integers in a lexicographic order.


Constructor Summary
LexicographicComparator()
           
 
Method Summary
 int compare(int[] t1, int[] t2)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

LexicographicComparator

public LexicographicComparator()
Method Detail

compare

public int compare(int[] t1,
                   int[] t2)
Specified by:
compare in interface Comparator<int[]>


Copyright © 2012. All Rights Reserved.