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 a constructor generation control annotation #181

Closed
lombokissues opened this issue Jul 14, 2015 · 6 comments
Closed

Add a constructor generation control annotation #181

lombokissues opened this issue Jul 14, 2015 · 6 comments

Comments

@lombokissues
Copy link

Migrated from Google Code (issue 108)

@lombokissues
Copy link
Author

👤 mkimberlin   🕗 Mar 20, 2010 at 04:13 UTC

Lombok would benefit from more granular control over the generation of
constructors.

See the discussion here: http://groups.google.com/group/project-
lombok/browse_thread/thread/553c771b5006e18f

This would likely take the form of a @ Constructors annotation with 3
potential parameters (noargs, minimal and all) each of which takes an enum
value where the enum is defined something like this:

public enum AccessLevel {
PUBLIC, PROTECTED
}

I don't think there is any reason for PRIVATE or PACKAGE in this case, but
perhaps I am overlooking a use case.

This combination would allow a developer to specify any reasonably
pragmatic combination of constructor types and specify the desired access
levels for each. As such:

@ Constructors(noargs=AccessLevel.PROTECTED, minimal=AccessLevel.PUBLIC,
all=AccessLevel.PUBLIC)

@lombokissues
Copy link
Author

👤 reinierz   🕗 Mar 20, 2010 at 08:15 UTC

AccessLevel already exists, fortunately :)

@lombokissues lombokissues added accepted The issue/enhancement is valid, sensible, and explained in sufficient detail enhancement labels Jul 14, 2015
@lombokissues
Copy link
Author

👤 reinierz   🕗 Jul 19, 2010 at 15:06 UTC

@lombokissues lombokissues added this to the 0.9.3 milestone Jul 14, 2015
@lombokissues
Copy link
Author

👤 reinierz   🕗 Jul 19, 2010 at 20:01 UTC

@lombokissues
Copy link
Author

👤 reinierz   🕗 Jul 19, 2010 at 20:01 UTC

Duplicate of issue #152

@lombokissues lombokissues added duplicate and removed accepted The issue/enhancement is valid, sensible, and explained in sufficient detail labels Jul 14, 2015
@lombokissues
Copy link
Author

End of migration

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

No branches or pull requests

1 participant