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

Provide mechanism for adding annotations to generated code #99

Open
Chessray opened this issue Nov 7, 2023 · 2 comments
Open

Provide mechanism for adding annotations to generated code #99

Chessray opened this issue Nov 7, 2023 · 2 comments

Comments

@Chessray
Copy link
Collaborator

Chessray commented Nov 7, 2023

In the spirit of the core's @AnnotateWith.

This would solve #3 as well.

@filiphr
Copy link
Member

filiphr commented Nov 13, 2023

@Chessray just my 2 cents for this. You can already use @AnnotateWith, you don't need to use a new annotation in the project. You'll need to do similar work though to parse the annotation and get the data out of it

@Chessray
Copy link
Collaborator Author

I believe we can make use of the annotation only for one case at the moment. While the core is clear in generating one implementation per @Mapper annotation, the extension is primarily configuration based. There's no 1:1 relationship between annotated classes and generated elements. We can add it to the @DelegatingConverter points, but for the rest I'm looking at adding new attributes to the config annotation. I wouldn't be sure how to interpret an @AnnotateWith on the config class.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

When branches are created from issues, their pull requests are automatically linked.

2 participants