Skip to content

Commit

Permalink
added @Valid annotation on bean validation template for java jaxs gen…
Browse files Browse the repository at this point in the history
…erators
  • Loading branch information
HugoMario committed Oct 22, 2020
1 parent 533f668 commit 1ea0c79
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
{{#required}}
@NotNull
{{/required}}
{{#isContainer}}
{{^isPrimitiveType}}
{{^isEnum}}
@Valid
{{/isEnum}}
{{/isPrimitiveType}}
{{/isContainer}}
{{#isNotContainer}}
{{^isPrimitiveType}}
@Valid
{{/isPrimitiveType}}
{{/isNotContainer}}
{{>beanValidationCore}}
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
{{#required}}
@NotNull
{{/required}}
{{#isContainer}}
{{^isPrimitiveType}}
{{^isEnum}}
@Valid
{{/isEnum}}
{{/isPrimitiveType}}
{{/isContainer}}
{{#isNotContainer}}
{{^isPrimitiveType}}
@Valid
{{/isPrimitiveType}}
{{/isNotContainer}}
{{>beanValidationCore}}
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import java.io.Serializable;
{{/serializableModel}}
{{#useBeanValidation}}
import javax.validation.constraints.*;
import javax.validation.Valid;
{{/useBeanValidation}}

{{#models}}
Expand Down

0 comments on commit 1ea0c79

Please sign in to comment.