public class MappedClassesOnlyHierarchyScanStrategy extends Object implements HierarchyScanStrategy
HierarchyScanStrategy
that excludes all ancestors of mapped classes, thus restricting
class scan to the mapped classes themselves.
This strategy can be used instead of DefaultHierarchyScanStrategy
to achieve pre-JAVA-541 behavior.
Constructor and Description |
---|
MappedClassesOnlyHierarchyScanStrategy() |
Modifier and Type | Method and Description |
---|---|
List<Class<?>> |
filterClassHierarchy(Class<?> mappedClass)
Computes the ancestors of the given base class, optionally filtering out any ancestor that
should not be scanned.
|
public MappedClassesOnlyHierarchyScanStrategy()
public List<Class<?>> filterClassHierarchy(Class<?> mappedClass)
HierarchyScanStrategy
Implementors should always include mappedClass
in the returned list.
filterClassHierarchy
in interface HierarchyScanStrategy
mappedClass
- The mapped class; this is necessarily a class annotated with either @Table
or @UDT
.mappedClass
itself and
its ancestors, ordered from the lowest (closest to mappedClass
) to the highest (or
farthest from mappedClass
).Copyright © 2012–2023. All rights reserved.