On Mon, 12 Apr 2021 16:44:16 GMT, Aleksei Efimov <[email protected]> wrote:
>> Conor Cleary has updated the pull request incrementally with two additional
>> commits since the last revision:
>>
>> - Update copyright headers
>> - Tidied up lambdas
>
> src/java.naming/share/classes/javax/naming/ldap/StartTlsRequest.java line 223:
>
>> 221: */
>> 222: private final ClassLoader getContextClassLoader() {
>> 223: PrivilegedAction<ClassLoader> pa = () ->
>> Thread.currentThread().getContextClassLoader();
>
> We can use here an instance method reference to beautify code a little bit
> more:
> ```PrivilegedAction<ClassLoader> pa =
> Thread.currentThread()::getContextClassLoader;```
Good idea, also would fit in with the style of the method just after,
`priviligedHasNext()` as that also uses a functional interface.
-------------
PR: https://git.openjdk.java.net/jdk/pull/3416