Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.openjpa.meta
Class InheritanceComparator

    java.lang.Object
      org.apache.openjpa.meta.InheritanceComparator

All Implemented Interfaces:
  Serializable, Comparator

Direct Known Subclasses:
  MetaDataInheritanceComparator

    public class InheritanceComparator

extends Object
implements Comparator, Serializable

Comparator that keeps classes in inheritance order.

Author:
  Abe White
See Also:
  Serialized Form

Constructor Summary
`InheritanceComparator()`

Method Summary
`int` | `compare(Object o1, Object o2)`
`Class` | `getBase()`
`void` | `setBase(Class base)` Set the least-derived type possible; defaults to `null`.
`protected Class` | `toClass(Object elem)` Subclasses can override this method to extract the class to compare on from the elements of the collection.

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

### InheritanceComparator

    public InheritanceComparator()

Method Detail

### setBase

    public void setBase(Class base)

  Set the least-derived type possible; defaults to `null`.

### getBase

    public Class getBase()

### toClass

    protected Class toClass(Object elem)

  Subclasses can override this method to extract the class to compare on from the elements of the collection.

### compare

    public int compare(Object o1,
                       Object o2)

  Specified by:
    `compare` in interface `Comparator`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2013 Apache Software Foundation. All Rights Reserved.