Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -159,25 +159,21 @@ public void hibernateValidatorProvidedCustomConstraints() {
assertFalse( compilationResult );
assertThatDiagnosticsMatch(
diagnostics,
new DiagnosticExpectation( Kind.ERROR, 57 ),
new DiagnosticExpectation( Kind.ERROR, 58 ),
new DiagnosticExpectation( Kind.ERROR, 59 ),
new DiagnosticExpectation( Kind.ERROR, 60 ),
new DiagnosticExpectation( Kind.ERROR, 61 ),
new DiagnosticExpectation( Kind.ERROR, 62 ),
new DiagnosticExpectation( Kind.ERROR, 63 ),
new DiagnosticExpectation( Kind.ERROR, 64 ),
new DiagnosticExpectation( Kind.ERROR, 65 ),
new DiagnosticExpectation( Kind.ERROR, 66 ),
new DiagnosticExpectation( Kind.ERROR, 67 ),
new DiagnosticExpectation( Kind.ERROR, 68 ),
new DiagnosticExpectation( Kind.ERROR, 69 ),
new DiagnosticExpectation( Kind.ERROR, 70 ),
new DiagnosticExpectation( Kind.ERROR, 71 ),
new DiagnosticExpectation( Kind.ERROR, 72 ),
new DiagnosticExpectation( Kind.ERROR, 73 ),
new DiagnosticExpectation( Kind.ERROR, 74 ),
new DiagnosticExpectation( Kind.ERROR, 75 ),
new DiagnosticExpectation( Kind.ERROR, 76 ),
new DiagnosticExpectation( Kind.ERROR, 77 ),
new DiagnosticExpectation( Kind.ERROR, 78 ),
new DiagnosticExpectation( Kind.ERROR, 79 ),
new DiagnosticExpectation( Kind.ERROR, 80 ),
new DiagnosticExpectation( Kind.ERROR, 81 ),
new DiagnosticExpectation( Kind.ERROR, 82 ),
new DiagnosticExpectation( Kind.ERROR, 83 ),
new DiagnosticExpectation( Kind.ERROR, 84 )
new DiagnosticExpectation( Kind.ERROR, 71 )
);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,10 @@
import java.util.Date;

import org.hibernate.validator.constraints.CreditCardNumber;
import org.hibernate.validator.constraints.Email;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.LuhnCheck;
import org.hibernate.validator.constraints.Mod10Check;
import org.hibernate.validator.constraints.Mod11Check;
import org.hibernate.validator.constraints.ModCheck;
import org.hibernate.validator.constraints.NotBlank;
import org.hibernate.validator.constraints.NotEmpty;
import org.hibernate.validator.constraints.Range;
import org.hibernate.validator.constraints.ScriptAssert;
import org.hibernate.validator.constraints.URL;
Expand All @@ -31,21 +27,16 @@
import org.hibernate.validator.constraints.time.DurationMin;

@ScriptAssert(script = "some script", lang = "javascript")
@SuppressWarnings("deprecation")
public class HibernateValidatorProvidedCustomConstraints {

/**
* Allowed.
*/
@CreditCardNumber
@Email
@Length
@LuhnCheck
@ModCheck(modType = ModCheck.ModType.MOD10, multiplier = 2)
@Mod10Check
@Mod11Check
@NotBlank
@NotEmpty
@Range
@URL
@CNPJ
Expand All @@ -64,14 +55,10 @@ public class HibernateValidatorProvidedCustomConstraints {
* Not allowed.
*/
@CreditCardNumber
@Email
@Length
@LuhnCheck
@ModCheck(modType = ModCheck.ModType.MOD10, multiplier = 2)
@Mod10Check
@Mod11Check
@NotBlank
@NotEmpty
@Range
@URL
@CNPJ
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,13 +76,6 @@ public interface BaseHibernateValidatorConfiguration<S extends BaseHibernateVali
*/
String ALLOW_PARALLEL_METHODS_DEFINE_PARAMETER_CONSTRAINTS = "hibernate.validator.allow_parallel_method_parameter_constraint";

/**
* @since 5.2
* @deprecated planned for removal. Use hibernate.validator.constraint_mapping_contributors instead.
*/
@Deprecated
String CONSTRAINT_MAPPING_CONTRIBUTOR = "hibernate.validator.constraint_mapping_contributor";

/**
* Property for configuring constraint mapping contributors, allowing to set up one or more constraint mappings for
* the default validator factory. Accepts a String with the comma separated fully-qualified class names of one or more
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
*/
package org.hibernate.validator;

import java.util.Locale;
import java.util.Set;

/**
Expand All @@ -26,13 +25,6 @@ public interface PredefinedScopeHibernateValidatorConfiguration extends BaseHibe
@Incubating
PredefinedScopeHibernateValidatorConfiguration initializeBeanMetaData(Set<Class<?>> beanClassesToInitialize);

/**
* @deprecated Planned for removal, use {@link BaseHibernateValidatorConfiguration#locales(Set)} instead.
*/
@Incubating
@Deprecated
PredefinedScopeHibernateValidatorConfiguration initializeLocales(Set<Locale> locales);

/**
* Specify whether to append the {@link #builtinConstraints(Set) built-in constraints} and {@link #initializeBeanMetaData(Set) beans to initialize}
* with constraints and beans provided only through XML mapping.
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
* @author Gunnar Morling
* @author Kevin Pollet &lt;[email protected]&gt; (C) 2011 SERLI
*/
@SuppressWarnings("deprecation")
public interface PropertyConstraintMappingContext
extends Constrainable<PropertyConstraintMappingContext>,
ConstraintMappingTarget,
Expand All @@ -23,6 +22,5 @@ public interface PropertyConstraintMappingContext
MethodTarget,
ContainerElementTarget,
Cascadable<PropertyConstraintMappingContext>,
AnnotationProcessingOptions<PropertyConstraintMappingContext>,
AnnotationIgnoreOptions<PropertyConstraintMappingContext> {
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@
*/
package org.hibernate.validator.cfg.context;

import java.lang.annotation.ElementType;

/**
* Facet of a constraint mapping creational context which allows to select the bean
* property to which the next operations shall apply.
Expand All @@ -16,24 +14,6 @@
* @author Gunnar Morling
*/
public interface PropertyTarget {
/**
* Selects a property to which the next operations shall apply.
* <p>
* 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.
* <p>
* A given property may only be configured once.
*
* @param property The property on which to apply the following constraints (Java Bean notation).
* @param type The access type (field/property).
*
* @return A creational context representing the selected property.
*
* @deprecated Since 6.1. Planned for removal. Use either {@link PropertyTarget#field(String)} or
* {@link PropertyTarget#getter(String)} instead.
*/
@Deprecated
PropertyConstraintMappingContext property(String property, ElementType type);

/**
* Selects a field to which the next operations shall apply.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,12 @@
* @author Kevin Pollet &lt;[email protected]&gt; (C) 2011 SERLI
* @author Gunnar Morling
*/
@SuppressWarnings("deprecation")
public interface TypeConstraintMappingContext<C>
extends Constrainable<TypeConstraintMappingContext<C>>,
ConstraintMappingTarget,
PropertyTarget,
MethodTarget,
ConstructorTarget,
AnnotationProcessingOptions<TypeConstraintMappingContext<C>>,
AnnotationIgnoreOptions<TypeConstraintMappingContext<C>> {

/**
Expand Down

This file was deleted.

105 changes: 0 additions & 105 deletions engine/src/main/java/org/hibernate/validator/constraints/ModCheck.java

This file was deleted.

Loading