DRAFT

javax.validation
Interface ConstraintValidatorContext.ConstraintViolationBuilder.NodeBuilderDefinedContext

Enclosing interface:
ConstraintValidatorContext.ConstraintViolationBuilder

public static interface ConstraintValidatorContext.ConstraintViolationBuilder.NodeBuilderDefinedContext

Represent a node whose context is known (ie index, key and isInIterable)


Method Summary
 ConstraintValidatorContext addConstraintViolation()
          Add the new ConstraintViolation to be generated if the constraint validator marks the value as invalid.
 ConstraintValidatorContext.ConstraintViolationBuilder.NodeBuilderCustomizableContext addNode(java.lang.String name)
          Add a node to the path the ConstraintViolation will be associated to.
 

Method Detail

addNode

ConstraintValidatorContext.ConstraintViolationBuilder.NodeBuilderCustomizableContext addNode(java.lang.String name)
Add a node to the path the ConstraintViolation will be associated to. name describes a single property. In particular, dot (.) are not allowed.

Parameters:
name - property name
Returns:
a builder representing this node

addConstraintViolation

ConstraintValidatorContext addConstraintViolation()
Add the new ConstraintViolation to be generated if the constraint validator marks the value as invalid. Methods of the ConstraintViolationBuilder instance this object comes from and the constraint violation builder nested objects return IllegalStateException after this call.

Returns:
ConstraintValidatorContext instance the ConstraintViolationBuilder comes from

DRAFT

Submit a bug or feature

Copyright © 2009 Sun Microsystems, Inc. All Rights Reserved. Use is subject to license terms.

Generated on 24-November-2009 03:24