nl.knowledgeplaza.util.reflection
Class ClassComparator

java.lang.Object
  extended by nl.knowledgeplaza.util.reflection.ClassComparator
All Implemented Interfaces:
java.util.Comparator

public final class ClassComparator
extends java.lang.Object
implements java.util.Comparator

Comparator that can compare classes. A Class is greater than its superClasses.


Field Summary
static java.lang.String SOURCECODE_VERSION
          Standard variable for determining version of a class file.
 
Constructor Summary
ClassComparator(boolean subclassLess, boolean interfaceLess)
          Creates a new Class Comparator with given options
 
Method Summary
 int compare(java.lang.Object o1, java.lang.Object o2)
           
 
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
 

Field Detail

SOURCECODE_VERSION

public static final transient java.lang.String SOURCECODE_VERSION
Standard variable for determining version of a class file.

See Also:
Constant Field Values
Constructor Detail

ClassComparator

public ClassComparator(boolean subclassLess,
                       boolean interfaceLess)
Creates a new Class Comparator with given options

Parameters:
subclassLess - true -> subclass < superclass
interfaceLess - true -> interface < class
Method Detail

compare

public int compare(java.lang.Object o1,
                   java.lang.Object o2)
Specified by:
compare in interface java.util.Comparator


Copyright © 2010. All Rights Reserved.