org.hibernate.validator.internal.cfg
Class DefaultConstraintMapping

java.lang.Object
  extended by org.hibernate.validator.internal.cfg.DefaultConstraintMapping
All Implemented Interfaces:
ConstraintMapping

public class DefaultConstraintMapping
extends Object
implements ConstraintMapping

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
           
 
Constructor Summary
DefaultConstraintMapping()
           
 
Method Summary
 ConstraintMappingContext getContext()
           
<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

protected ConstraintMappingContext context
Constructor Detail

DefaultConstraintMapping

public DefaultConstraintMapping()
Method Detail

type

public final <C> TypeConstraintMappingContext<C> type(Class<C> beanClass)
Description copied from interface: ConstraintMapping
Starts defining constraints on the specified bean class.

Specified by:
type in interface ConstraintMapping
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.

getContext

public ConstraintMappingContext getContext()


Copyright © 2012 Oracle Corporation. All Rights Reserved.