java.lang.Object | |
↳ | org.hibernate.util.ReflectHelper |
Utility class for various reflection operations.
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
NO_PARAMS | |||||||||||
NO_PARAM_SIGNATURE | |||||||||||
SINGLE_OBJECT_PARAM_SIGNATURE |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Perform resolution of a class name.
| |||||||||||
Perform resolution of a class name.
| |||||||||||
Encapsulation of getting hold of a class's
equals method. | |||||||||||
Encapsulation of getting hold of a class's
hashCode method. | |||||||||||
Resolve a constant to its actual value.
| |||||||||||
Retrieve a constructor for the given class, with arguments matching the specified Hibernate mapping
types . | |||||||||||
Retrieve the default (no arg) constructor from the given class.
| |||||||||||
Directly retrieve the
Getter reference via the BasicPropertyAccessor . | |||||||||||
Determine if the given class implements the given interface.
| |||||||||||
Determine if the given class is declared abstract.
| |||||||||||
Determine is the given class is declared final.
| |||||||||||
Is this member publicly accessible.
| |||||||||||
Is this member publicly accessible.
| |||||||||||
Determine if the given class defines an
equals(Object) override. | |||||||||||
Determine if the given class defines a
hashCode() override. | |||||||||||
Attempt to resolve the specified property type through reflection.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Perform resolution of a class name.
Here we first check the context classloader, if one, before delegating toforName(String, boolean, ClassLoader)
using the caller's classloadername | The class name |
---|---|
caller | The class from which this call originated (in order to access that class's loader). |
Perform resolution of a class name.
Same asclassForName(String, Class)
except that here we delegate to
forName(String)
if the context classloader lookup is unsuccessful.name | The class name |
---|
ClassNotFoundException | From forName(String) .
|
---|
Encapsulation of getting hold of a class's equals
method.
clazz | The class from which to extract the equals method. |
---|
NoSuchMethodException | Should indicate an attempt to extract equals method from interface. |
---|
Encapsulation of getting hold of a class's hashCode
method.
clazz | The class from which to extract the hashCode method. |
---|
NoSuchMethodException | Should indicate an attempt to extract hashCode method from interface. |
---|
Resolve a constant to its actual value.
name | The name |
---|
Retrieve a constructor for the given class, with arguments matching the specified Hibernate mapping
types
.
clazz | The class needing instantiation |
---|---|
types | The types representing the required ctor param signature |
PropertyNotFoundException | Indicates we could not locate an appropriate constructor (todo : again with PropertyNotFoundException???) |
---|
Retrieve the default (no arg) constructor from the given class.
clazz | The class for which to retrieve the default ctor. |
---|
PropertyNotFoundException | Indicates there was not publicly accessible, no-arg constructor (todo : why PropertyNotFoundException???) |
---|
Directly retrieve the Getter
reference via the BasicPropertyAccessor
.
theClass | The class owning the property |
---|---|
name | The name of the property |
MappingException | Indicates we were unable to locate the property. |
---|
Determine if the given class implements the given interface.
clazz | The class to check |
---|---|
intf | The interface to check it against. |
Determine if the given class is declared abstract.
clazz | The class to check. |
---|
Determine is the given class is declared final.
clazz | The class to check. |
---|
Is this member publicly accessible.
Short-hand forisPublic(Class, Member)
passing the member + getDeclaringClass()
member | The member to check |
---|
Is this member publicly accessible.
clazz | The class which defines the member |
---|---|
member | The memeber. |
Determine if the given class defines an equals(Object)
override.
clazz | The class to check |
---|
Determine if the given class defines a hashCode()
override.
clazz | The class to check |
---|
Attempt to resolve the specified property type through reflection.
className | The name of the class owning the property. |
---|---|
name | The name of the property. |
MappingException | Indicates we were unable to locate the property. |
---|