On Fri, 14 Mar 2025 02:46:47 GMT, Weijun Wang <wei...@openjdk.org> wrote:

>> If they are common, would it make more sense to include them as parameters 
>> to an overloaded version of the static `of` method?
>
> I'd rather not. There are already three `of` methods. Adding `info` would 
> make make six, and adding `encapsulation` would be twelve. I cannot say which 
> combination is more popular than another one.
> 
> Also,  the arguments of the current `of` methods are all about algorithm 
> identifiers. Adding `info` and `encapsulation` to the argument list could 
> make the API harder to use, as the method signature only includes the types 
> of the parameters but not their meanings. While providing them through the 
> `info` and `encapsulation` methods are very clean. They also have 
> accompanying "getter" methods with the same names.

Ok.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/18411#discussion_r2298857635

Reply via email to