org.hibernate.validator.cfg
Class ConstraintMapping

java.lang.Object
  extended by org.hibernate.validator.cfg.ConstraintMapping

public class ConstraintMapping
extends Object

Top level class for constraints configured via the programmatic API. This class is not intended to be inherited by clients. It will be converted into an interface in a future release.

Author:
Hardy Ferentschik, Gunnar Morling, Kevin Pollet (C) 2011 SERLI

Field Summary
protected  ConstraintMappingContext context
          Deprecated. Will be removed in a future release.
 
Constructor Summary
  ConstraintMapping()
          Deprecated. This class will be converted into an interface in a future release. Use HibernateValidatorConfiguration.createConstraintMapping() instead to create new constraint mappings.
protected ConstraintMapping(ConstraintMapping original)
          Deprecated. This class will be converted into an interface in a future release. Use HibernateValidatorConfiguration.createConstraintMapping() instead to create new constraint mappings.
 
Method Summary
<C> TypeConstraintMappingContext<C>
type(Class<C> beanClass)
          Starts defining constraints on the specified bean class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

context

@Deprecated
protected ConstraintMappingContext context
Deprecated. Will be removed in a future release.
Not intended for public use.

Constructor Detail

ConstraintMapping

@Deprecated
public ConstraintMapping()
Deprecated. This class will be converted into an interface in a future release. Use HibernateValidatorConfiguration.createConstraintMapping() instead to create new constraint mappings.


ConstraintMapping

@Deprecated
protected ConstraintMapping(ConstraintMapping original)
Deprecated. This class will be converted into an interface in a future release. Use HibernateValidatorConfiguration.createConstraintMapping() instead to create new constraint mappings.

Method Detail

type

public final <C> TypeConstraintMappingContext<C> type(Class<C> beanClass)
Starts defining constraints on the specified bean class.

Type Parameters:
C - The type to be configured.
Parameters:
beanClass - The bean class on which to define constraints. All constraints defined after calling this method are added to the bean of the type beanClass until the next call of type.
Returns:
Instance allowing for defining constraints on the specified class.


Copyright © 2012 Oracle Corporation. All Rights Reserved.