nl.knowledgeplaza.util.reflection
Class ClassComparator

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

public final class ClassComparator
extends Object
implements Comparator

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


Field Summary
static 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(Object o1, 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 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(Object o1,
                   Object o2)
Specified by:
compare in interface Comparator


Copyright © 2011 KnowledgePlaza. All Rights Reserved.