org.hibernate.validator.internal.metadata.aggregated

## Interface ConstraintMetaData

- All Superinterfaces:
    Iterable<MetaConstraint<?>>
  All Known Implementing Classes:
    AbstractConstraintMetaData, ExecutableMetaData, ParameterMetaData, PropertyMetaData, ReturnValueMetaData

      public interface ConstraintMetaData
      extends Iterable<MetaConstraint<?>>

  An aggregated view of the constraint related meta data for a given bean/type element and all the elements in the inheritance hierarchy which it overrides or implements.
  Author:
    Gunnar Morling

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `ElementDescriptor` | `asDescriptor(boolean defaultGroupSequenceRedefined, List<Class<?>> defaultGroupSequence)` Returns this meta data object's corresponding representation in the descriptor model.
    `ElementKind` | `getKind()` Returns the `kind` of this meta data object.
    `String` | `getName()` Returns the name of this meta data object.
    `Type` | `getType()` Returns the data type of this meta data object, e.g.
    `boolean` | `isCascading()` Whether this meta data object is marked for cascaded validation or not.
    `boolean` | `isConstrained()` Whether this meta data object is constrained by any means or not.
    `boolean` | `requiresUnwrapping()` Whether the value to be validated needs to be unwrapped (which is the case if this element is annotated with `@UnwrapValidatedValue`) or not.

    - ### Methods inherited from interface java.lang.Iterable

      `iterator`

- - ### Method Detail

    - #### getName

          String getName()

      Returns the name of this meta data object.
      Returns:
        This meta data object's name.

    - #### getType

          Type getType()

      Returns the data type of this meta data object, e.g. the type of a bean property or the return type of a method.
      Returns:
        This meta data object's type.

    - #### getKind

          ElementKind getKind()

      Returns the `kind` of this meta data object.
      Returns:
        The `kind` of this meta data object.

    - #### isCascading

          boolean isCascading()

      Whether this meta data object is marked for cascaded validation or not.
      Returns:
        `True` if this object is marked for cascaded validation, `false` otherwise.

    - #### isConstrained

          boolean isConstrained()

      Whether this meta data object is constrained by any means or not.
      Returns:
        `True` if this object is marked for cascaded validation or has any constraints, `false` otherwise.

    - #### asDescriptor

          ElementDescriptor asDescriptor(boolean defaultGroupSequenceRedefined,
                                       List<Class<?>> defaultGroupSequence)

      Returns this meta data object's corresponding representation in the descriptor model.
      Parameters:
        `defaultGroupSequenceRedefined` - Whether the bean hosting the represented element has a redefined default group sequence or not.
        `defaultGroupSequence` - The default group sequence of the bean hosting the represented element.
      Returns:
        This meta data object's corresponding descriptor model representation. Implementations should return a specific sub type of `ElementDescriptor`.

    - #### requiresUnwrapping

          boolean requiresUnwrapping()

      Whether the value to be validated needs to be unwrapped (which is the case if this element is annotated with `@UnwrapValidatedValue`) or not.
      Returns:
        `true` if the value to be validated needs to unwrapped, `false` otherwise.

Copyright © 2007-2014 Red Hat, Inc. All Rights Reserved