Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for constrainst annotations #58

Open
HamzaBenyazid opened this issue Oct 19, 2023 · 0 comments
Open

Add support for constrainst annotations #58

HamzaBenyazid opened this issue Oct 19, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@HamzaBenyazid
Copy link
Collaborator

HamzaBenyazid commented Oct 19, 2023

Using annotations from javax.validation.constraints is very common in developing an app using JEE, spring or any other java framework. It's used to validate field values of java beans.
For example :

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

public class User {
    @NotNull
    private String username;

    @Size(min = 6, max = 20)
    private String password;

    // Constructor, methods, etc.
}

A good feature to have is to generate these beans respecting the constraints annotations.
These annotations serve as just metadata, and will not validate until you use a validator, like Hibernate Validator.

Image

So the goal is to implement a way for reading these constraints and generate objects that respect them

@HamzaBenyazid HamzaBenyazid converted this from a draft issue Oct 19, 2023
@HamzaBenyazid HamzaBenyazid self-assigned this Oct 30, 2023
@HamzaBenyazid HamzaBenyazid added the enhancement New feature or request label Oct 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant