org.hibernate.validator.internal.metadata.location
Class BeanConstraintLocation
java.lang.Object
org.hibernate.validator.internal.metadata.location.BeanConstraintLocation
- All Implemented Interfaces:
- ConstraintLocation
public class BeanConstraintLocation
- extends Object
- implements ConstraintLocation
A ConstraintLocation implementation that represents either a bean (in case of class-level
constraints), a field or a getter method (in case of property-level constraints).
- Author:
- Hardy Ferentschik, Gunnar Morling
BeanConstraintLocation
public BeanConstraintLocation(Class<?> beanClass)
BeanConstraintLocation
public BeanConstraintLocation(Member member)
BeanConstraintLocation
public BeanConstraintLocation(Class<?> beanClass,
Member member)
- Parameters:
beanClass - The class in which the constraint is defined onmember - The member on which the constraint is defined on, null if it is a class constraint}
getBeanClass
public Class<?> getBeanClass()
- Specified by:
getBeanClass in interface ConstraintLocation
getMember
public Member getMember()
- Specified by:
getMember in interface ConstraintLocation
typeOfAnnotatedElement
public Type typeOfAnnotatedElement()
- Description copied from interface:
ConstraintLocation
- Returns the type of the element at this constraint location. Depending
on the concrete implementation this might be the type of an annotated bean, method parameter etc.
- Specified by:
typeOfAnnotatedElement in interface ConstraintLocation
- Returns:
- The type of the element at this constraint location.
getElementType
public ElementType getElementType()
- Specified by:
getElementType in interface ConstraintLocation
equals
public boolean equals(Object o)
- Overrides:
equals in class Object
hashCode
public int hashCode()
- Overrides:
hashCode in class Object
toString
public String toString()
- Overrides:
toString in class Object
Copyright © 2012 Oracle Corporation. All Rights Reserved.