All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.hibernate.validator.internal.metadata.facets.Validatable Maven / Gradle / Ivy

There is a newer version: 8.0.1.Final
Show newest version
/*
 * Hibernate Validator, declare and validate application constraints
 *
 * License: Apache License, Version 2.0
 * See the license.txt file in the root directory or .
 */
package org.hibernate.validator.internal.metadata.facets;

/**
 * Provides a unified view on validatable elements of all kinds, be it Java
 * beans, the arguments passed to a method or the value returned from a method.
 * Allows a unified handling of these elements in the validation routine.
 *
 * @author Gunnar Morling
 */
public interface Validatable {

	/**
	 * Returns the cascaded elements of this validatable, e.g. the properties of
	 * a bean or the parameters of a method annotated with {@code @Valid}.
	 *
	 * @return The cascaded elements of this validatable.
	 */
	Iterable getCascadables();

	/**
	 * Returns {@code true} if this validatable has at least one cascadable element, {@code false} otherwise.
	 */
	boolean hasCascadables();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy