In Spring Boot, to create a custom constraint annotation, you should create an annotation interface and a corresponding _____ class to implement the validation logic.
- ConstraintValidator
- ValidationHandler
- SpringBootValidator
- AnnotationValidator
To create a custom constraint annotation in Spring Boot, you need to create an annotation interface and a corresponding ConstraintValidator class to implement the validation logic. The ConstraintValidator interface allows you to define custom validation rules for your annotation, making it a crucial part of custom validation. The other options are not standard components used for creating custom constraint annotations.
Loading...
Related Quiz
- In Spring Boot, to order the execution of validation groups, the _____ interface needs to be implemented along with defining a sequence list of groups.
- Which of the following can be used to enable method security annotations in a Spring Security configuration class?
- In Spring Boot, the _____ annotation is used to conditionally enable a configuration based on the presence of a specific property.
- How can a custom auto-configuration be created in Spring Boot?
- To enable method-level security annotations like @Secured and @PreAuthorize, the _____ attribute needs to be enabled in the security configuration.