-
Notifications
You must be signed in to change notification settings - Fork 115
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
Support BitSet look up out of box #570
Comments
Isn't this type too specific for a built in converter? |
What do you mean? I think it is useful to add it to the list of built in converter. |
Why
And probably a lot others. I would argue there are some much more widely used than |
@tomas-langer most of the converters you mentioned are already supported and they are under automatic converter category. See the category details here. In more details, If no built-in nor custom Converter exists for a requested Type T, an implicit Converter is automatically provided if the following conditions are met:
This leaves UUID, Charset, and Pattern. For the old time classes, I think the java.time is more preferred and they become legacy. I suggest not to do anything for them. I will open another issue to support UUID, Charset and Pattern as built-in converters. In the meanwhile, I'm going to close this issue of adding Bitset as built-in converter since not many people are keen with this. |
See #604 @tomas-langer please comment if you think more converters are to be added. I believe I have address your comments. |
As a:
...I need to be able to:
directly inject or programmatically look BitSet in my java class without providing a converter myself.
...which enables me to:
Specify a bitset in a configsource and then I can look up from my java class
bits=10001
@Inject @ConfigProperty(name="bits") BitSet bits;
The text was updated successfully, but these errors were encountered: