public class ProxyUtil extends Object
ProxyUtil
Various utility methods dealing with proxies
Constructor and Description |
---|
ProxyUtil() |
Modifier and Type | Method and Description |
---|---|
static Object |
getHibernateProxyTarget(Object object) |
static boolean |
isHibernateProxy(Object object)
Check whether the given object is a Hibernate proxy.
|
static boolean |
isHibernateProxyMember(Member member)
Check whether the given member is a member of a Hibernate proxy.
|
static boolean |
isProxy(Object object)
Check whether the given object is a proxy.
|
static boolean |
isProxyMember(Member member,
Object object)
Check whether the given member is a proxy member of a proxy object or is a static proxy member.
|
static Member |
resolveTargetMember(Member proxyMember,
Object target) |
static Class<?> |
ultimateTargetClass(Object candidate)
Determine the ultimate target class of the given instance, traversing
not only a top-level proxy but any number of nested proxies as well —
as long as possible without side effects.
|
public static Class<?> ultimateTargetClass(Object candidate)
candidate
- the instance to check (might be a proxy)null
)public static boolean isProxy(Object object)
object
- the object to checkpublic static boolean isProxyMember(Member member, Object object)
member
- the member to checkobject
- the object to checkpublic static boolean isHibernateProxy(Object object)
object
- the object to checkpublic static boolean isHibernateProxyMember(Member member)
member
- the member to checkpublic static Object getHibernateProxyTarget(Object object)
Copyright © 2000–2024 Apache Software Foundation. All rights reserved.