public final class ReturnValueConstraintMappingContextImpl extends CascadableConstraintMappingContextImplBase<ReturnValueConstraintMappingContext> implements ReturnValueConstraintMappingContext
groupConversions, isCascading
mapping
Constructor and Description |
---|
ReturnValueConstraintMappingContextImpl(ExecutableConstraintMappingContextImpl executableContext) |
Modifier and Type | Method and Description |
---|---|
ReturnValueConstraintMappingContext |
constraint(ConstraintDef<?,?> definition)
Adds a new constraint.
|
ConstructorConstraintMappingContext |
constructor(Class<?>... parameterTypes)
Selects a constructor to which the next operations shall apply.
|
CrossParameterConstraintMappingContext |
crossParameter()
Selects the cross-parameter element of a method or constructor as target for the next constraint declaration
operations.
|
protected ConstraintDescriptorImpl.ConstraintType |
getConstraintType()
Returns the type of constraints hosted on the element configured by this creational context.
|
protected ReturnValueConstraintMappingContext |
getThis()
Returns this object, narrowed down to the specific sub-type.
|
MethodConstraintMappingContext |
method(String name,
Class<?>... parameterTypes)
Selects a method to which the next operations shall apply.
|
ParameterConstraintMappingContext |
parameter(int index)
Changes the parameter for which added constraints apply.
|
addGroupConversion, convertGroup, getGroupConversions, isCascading, valid
addConstraint, getConstraintMapping, getConstraints, type
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
type
convertGroup, valid
public ReturnValueConstraintMappingContextImpl(ExecutableConstraintMappingContextImpl executableContext)
protected ReturnValueConstraintMappingContext getThis()
CascadableConstraintMappingContextImplBase
getThis
in class CascadableConstraintMappingContextImplBase<ReturnValueConstraintMappingContext>
public ReturnValueConstraintMappingContext constraint(ConstraintDef<?,?> definition)
Constrainable
constraint
in interface Constrainable<ReturnValueConstraintMappingContext>
definition
- The constraint to add.public ParameterConstraintMappingContext parameter(int index)
ParameterTarget
parameter
in interface ParameterTarget
index
- The parameter index.public CrossParameterConstraintMappingContext crossParameter()
CrossParameterTarget
crossParameter
in interface CrossParameterTarget
public MethodConstraintMappingContext method(String name, Class<?>... parameterTypes)
MethodTarget
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.
method
in interface MethodTarget
name
- The method name.parameterTypes
- The method parameter types.public ConstructorConstraintMappingContext constructor(Class<?>... parameterTypes)
ConstructorTarget
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.
constructor
in interface ConstructorTarget
parameterTypes
- The constructor parameter types.protected ConstraintDescriptorImpl.ConstraintType getConstraintType()
ConstraintMappingContextImplBase
getConstraintType
in class ConstraintMappingContextImplBase
Copyright © 2007-2013 Red Hat, Inc. All Rights Reserved