Top Description Fields Constructors Methods
org.hibernate.validator.internal.cfg.context

pack-priv abstract Class AbstractPropertyConstraintMappingContextImpl<T extends org.hibernate.validator.internal.properties.Property>

extends CascadableConstraintMappingContextImplBase<PropertyConstraintMappingContext>
implements PropertyConstraintMappingContext
Class Inheritance
All Implemented Interfaces
org.hibernate.validator.cfg.context.PropertyConstraintMappingContext, org.hibernate.validator.cfg.context.AnnotationIgnoreOptions, org.hibernate.validator.cfg.context.AnnotationProcessingOptions, org.hibernate.validator.cfg.context.Cascadable, org.hibernate.validator.cfg.context.ContainerElementTarget, org.hibernate.validator.cfg.context.MethodTarget, org.hibernate.validator.cfg.context.ConstructorTarget, org.hibernate.validator.cfg.context.PropertyTarget, org.hibernate.validator.cfg.context.ConstraintMappingTarget, org.hibernate.validator.cfg.context.ConstraintDefinitionTarget, org.hibernate.validator.cfg.context.TypeTarget, org.hibernate.validator.cfg.context.Constrainable
Known Direct Subclasses
org.hibernate.validator.internal.cfg.context.FieldConstraintMappingContextImpl, org.hibernate.validator.internal.cfg.context.GetterConstraintMappingContextImpl
Imports
java.lang.annotation.ElementType, org.hibernate.validator.cfg.context.ConstructorConstraintMappingContext, .ContainerElementConstraintMappingContext, .MethodConstraintMappingContext, .PropertyConstraintMappingContext, org.hibernate.validator.internal.engine.ConstraintCreationContext, org.hibernate.validator.internal.metadata.descriptor.ConstraintDescriptorImpl.ConstraintType, org.hibernate.validator.internal.metadata.location.ConstraintLocation, org.hibernate.validator.internal.metadata.raw.ConstrainedElement, org.hibernate.validator.internal.properties.Property

Deprecated

as a consequence of PropertyConstraintMappingContext being deprecated. See corresponding docs for further information.

Constraint mapping creational context which allows to configure the constraints for one bean property.
Authors
Hardy Ferentschik, Gunnar Morling, Kevin Pollet <[email protected]> (C) 2011 SERLI, Marko Bekhta

Field Summary

Modifier and TypeField and Description
private final ConstraintLocation
private final T
private final TypeConstraintMappingContextImpl<?>
typeContext

Deprecated as a consequence of TypeConstraintMappingContextImpl being deprecated.
Inherited from org.hibernate.validator.internal.cfg.context.CascadableConstraintMappingContextImplBase:
groupConversionsisCascading

Constructor Summary

AccessConstructor and Description
protected
AbstractPropertyConstraintMappingContextImpl(TypeConstraintMappingContextImpl<?> typeContext, T property, ConstraintLocation location)

Deprecated as a consequence of TypeConstraintMappingContextImpl being deprecated.

Method Summary

Modifier and TypeMethod and Description
pack-priv abstract ConstrainedElement
build(ConstraintCreationContext constraintCreationContext)

public ConstructorConstraintMappingContext
constructor(Class<?>...
The constructor parameter types.
parameterTypes
)

Implements org.hibernate.validator.cfg.context.ConstructorTarget.constructor.

Selects a constructor to which the next operations shall apply.
public ContainerElementConstraintMappingContext
containerElementType()

Implements org.hibernate.validator.cfg.context.ContainerElementTarget.containerElementType.

Selects the single type argument of the current element's generic type as the target for the next operations.
public ContainerElementConstraintMappingContext
containerElementType(int
The index of the type argument to configure. Pass 0 when navigating into an array type.
index
,
int...
the nested index(es) in case the container element to configure is a generic type within another generic type, e.g. List<Map<String, String>>, a multi-dimensional array or a combination of (nested) parameterized and array types.
nestedIndexes
)

Implements org.hibernate.validator.cfg.context.ContainerElementTarget.containerElementType.

Selects the single type argument of the current element's generic type as the target for the next operations.
public PropertyConstraintMappingContext
field(String
The field name that represents a property on which to apply the following constraints.
property
)

Implements org.hibernate.validator.cfg.context.PropertyTarget.field.

Deprecated as a consequence of PropertyConstraintMappingContext being deprecated.
Selects a field to which the next operations shall apply.
protected ConstraintDescriptorImpl.ConstraintType
getConstraintType()

Implements abstract org.hibernate.validator.internal.cfg.context.ConstraintMappingContextImplBase.getConstraintType.

Returns the type of constraints hosted on the element configured by this creational context.
protected T
public PropertyConstraintMappingContext
getter(String
The getter property name (using the Java Bean notation, e.g. name to address getName()) that represents a property on which to apply the following constraints.
property
)

Implements org.hibernate.validator.cfg.context.PropertyTarget.getter.

Deprecated as a consequence of PropertyConstraintMappingContext being deprecated.
Selects a getter to which the next operations shall apply.
protected AbstractPropertyConstraintMappingContextImpl<?>
getThis()

Implements abstract org.hibernate.validator.internal.cfg.context.CascadableConstraintMappingContextImplBase.getThis.

Deprecated as a consequence of AbstractPropertyConstraintMappingContextImpl being deprecated.
Returns this object, narrowed down to the specific sub-type.
public PropertyConstraintMappingContext
public PropertyConstraintMappingContext
ignoreAnnotations(boolean
Whether to ignore annotation-based constraints or not.
ignoreAnnotations
)

Implements org.hibernate.validator.cfg.context.AnnotationIgnoreOptions.ignoreAnnotations.

Deprecated as a consequence of PropertyConstraintMappingContext being deprecated.
Specifies whether annotations at the given element should be ignored or not, overriding any setting given for parent elements.
public MethodConstraintMappingContext
method(String
The method name.
name
,
Class<?>...
The method parameter types.
parameterTypes
)

Implements org.hibernate.validator.cfg.context.MethodTarget.method.

Selects a method to which the next operations shall apply.
public PropertyConstraintMappingContext
property(String
The property on which to apply the following constraints (Java Bean notation).
property
,
ElementType
The access type (field/property).
elementType
)

Implements org.hibernate.validator.cfg.context.PropertyTarget.property.

Deprecated as a consequence of PropertyConstraintMappingContext being deprecated.
Selects a property to which the next operations shall apply.
Inherited from org.hibernate.validator.internal.cfg.context.CascadableConstraintMappingContextImplBase:
addGroupConversioncontainerElementcontainerElementconvertGroupgetCascadingMetaDataBuildergetTypeArgumentConstraintsisCascadingvalid

Field Detail

locationback to summary
private final ConstraintLocation location
propertyback to summary
private final T property
typeContextback to summary
private final TypeConstraintMappingContextImpl<?> typeContext

Deprecated

as a consequence of TypeConstraintMappingContextImpl being deprecated. See corresponding docs for further information.

Constructor Detail

AbstractPropertyConstraintMappingContextImplback to summary
protected AbstractPropertyConstraintMappingContextImpl(TypeConstraintMappingContextImpl<?> typeContext, T property, ConstraintLocation location)

Deprecated

as a consequence of TypeConstraintMappingContextImpl being deprecated. See corresponding docs for further information.

Method Detail

buildback to summary
pack-priv abstract ConstrainedElement build(ConstraintCreationContext constraintCreationContext)
constructorback to summary
public ConstructorConstraintMappingContext constructor(Class<?>... parameterTypes)

Implements org.hibernate.validator.cfg.context.ConstructorTarget.constructor.

Doc from org.hibernate.validator.cfg.context.ConstructorTarget.constructor.

Selects a constructor to which the next operations shall apply.

Until this method is called constraints apply on class level. After calling this method constraints apply to the specified constructor.

A given constructor may only be configured once.

Parameters
parameterTypes:Class<?>[]

The constructor parameter types.

Returns:ConstructorConstraintMappingContext

A creational context representing the selected constructor.

Annotations
@Override
containerElementTypeback to summary
public ContainerElementConstraintMappingContext containerElementType()

Implements org.hibernate.validator.cfg.context.ContainerElementTarget.containerElementType.

Doc from org.hibernate.validator.cfg.context.ContainerElementTarget.containerElementType.

Selects the single type argument of the current element's generic type as the target for the next operations. Selects the component type if the current element is of an array type.

Returns:ContainerElementConstraintMappingContext

A creational context representing the single type argument or the component type of the current element's type.

Annotations
@Override
containerElementTypeback to summary
public ContainerElementConstraintMappingContext containerElementType(int index, int... nestedIndexes)

Implements org.hibernate.validator.cfg.context.ContainerElementTarget.containerElementType.

Doc from org.hibernate.validator.cfg.context.ContainerElementTarget.containerElementType.

Selects the single type argument of the current element's generic type as the target for the next operations. Selects the component type if the current element is of an array type.

Parameters
index:int

The index of the type argument to configure. Pass 0 when navigating into an array type.

nestedIndexes:int[]

the nested index(es) in case the container element to configure is a generic type within another generic type, e.g. List<Map<String, String>>, a multi-dimensional array or a combination of (nested) parameterized and array types.

Returns:ContainerElementConstraintMappingContext

A creational context representing the specified type argument.

Annotations
@Override
fieldback to summary
public PropertyConstraintMappingContext field(String property)

Implements org.hibernate.validator.cfg.context.PropertyTarget.field.

Doc from org.hibernate.validator.cfg.context.PropertyTarget.field.

Deprecated

as a consequence of PropertyConstraintMappingContext being deprecated. See corresponding docs for further information.

Selects a field to which the next operations shall apply.

Until this method is called constraints apply on class level. After calling this method constraints apply on the specified field property.

A given field may only be configured once.

Parameters
property:String

The field name that represents a property on which to apply the following constraints.

Returns:PropertyConstraintMappingContext

A creational context representing the selected field property.

Annotations
@Override
getConstraintTypeback to summary
protected ConstraintDescriptorImpl.ConstraintType getConstraintType()

Implements abstract org.hibernate.validator.internal.cfg.context.ConstraintMappingContextImplBase.getConstraintType.

Doc from org.hibernate.validator.internal.cfg.context.ConstraintMappingContextImplBase.getConstraintType.

Returns the type of constraints hosted on the element configured by this creational context.

Returns:ConstraintDescriptorImpl.ConstraintType

the type of constraints hosted on the element configured by this creational context

Annotations
@Override
getPropertyback to summary
protected T getProperty()
getterback to summary
public PropertyConstraintMappingContext getter(String property)

Implements org.hibernate.validator.cfg.context.PropertyTarget.getter.

Doc from org.hibernate.validator.cfg.context.PropertyTarget.getter.

Deprecated

as a consequence of PropertyConstraintMappingContext being deprecated. See corresponding docs for further information.

Selects a getter to which the next operations shall apply.

Until this method is called constraints apply on class level. After calling this method constraints apply on the specified getter property.

A given getter may only be configured once.

Parameters
property:String

The getter property name (using the Java Bean notation, e.g. name to address getName()) that represents a property on which to apply the following constraints.

Returns:PropertyConstraintMappingContext

A creational context representing the selected getter property.

Annotations
@Override
getThisback to summary
protected AbstractPropertyConstraintMappingContextImpl<?> getThis()

Implements abstract org.hibernate.validator.internal.cfg.context.CascadableConstraintMappingContextImplBase.getThis.

Doc from org.hibernate.validator.internal.cfg.context.CascadableConstraintMappingContextImplBase.getThis.

Deprecated

as a consequence of AbstractPropertyConstraintMappingContextImpl being deprecated. See corresponding docs for further information.

Returns this object, narrowed down to the specific sub-type.

Returns:AbstractPropertyConstraintMappingContextImpl<?>

this object, narrowed down to the specific sub-type

Annotations
@Override
ignoreAnnotationsback to summary
public PropertyConstraintMappingContext ignoreAnnotations()

Implements org.hibernate.validator.cfg.context.AnnotationProcessingOptions.ignoreAnnotations.

Deprecated

as a consequence of PropertyConstraintMappingContext being deprecated. See corresponding docs for further information.

Annotations
@Override
@SuppressWarnings:deprecation
ignoreAnnotationsback to summary
public PropertyConstraintMappingContext ignoreAnnotations(boolean ignoreAnnotations)

Implements org.hibernate.validator.cfg.context.AnnotationIgnoreOptions.ignoreAnnotations.

Doc from org.hibernate.validator.cfg.context.AnnotationIgnoreOptions.ignoreAnnotations.

Deprecated

as a consequence of PropertyConstraintMappingContext being deprecated. See corresponding docs for further information.

Specifies whether annotations at the given element should be ignored or not, overriding any setting given for parent elements. E.g. the setting given for a method parameter overrides the setting given for the method declaring that parameter.

Parameters
ignoreAnnotations:boolean

Whether to ignore annotation-based constraints or not.

Returns:PropertyConstraintMappingContext

This context for method chaining.

Annotations
@Override
methodback to summary
public MethodConstraintMappingContext method(String name, Class<?>... parameterTypes)

Implements org.hibernate.validator.cfg.context.MethodTarget.method.

Doc from org.hibernate.validator.cfg.context.MethodTarget.method.

Selects a method to which the next operations shall apply.

Until this method is called constraints apply on class level. After calling this method constraints apply to the specified method.

A given method may only be configured once.

Parameters
name:String

The method name.

parameterTypes:Class<?>[]

The method parameter types.

Returns:MethodConstraintMappingContext

A creational context representing the selected method.

Annotations
@Override
propertyback to summary
public PropertyConstraintMappingContext property(String property, ElementType elementType)

Implements org.hibernate.validator.cfg.context.PropertyTarget.property.

Doc from org.hibernate.validator.cfg.context.PropertyTarget.property.

Deprecated

as a consequence of PropertyConstraintMappingContext being deprecated. See corresponding docs for further information.

Selects a property to which the next operations shall apply.

Until this method is called constraints apply on class level. After calling this method constraints apply on the specified property with the given access type.

A given property may only be configured once.

Parameters
property:String

The property on which to apply the following constraints (Java Bean notation).

elementType:ElementType

The access type (field/property).

Returns:PropertyConstraintMappingContext

A creational context representing the selected property.

Annotations
@Override
@SuppressWarnings:deprecation