Integrated: 8254996: make jdk.net.UnixDomainPrincipal a record class
Patrick Concannon
pconcannon at openjdk.java.net
Wed Dec 9 17:06:35 UTC 2020
On Mon, 7 Dec 2020 15:32:54 GMT, Patrick Concannon <pconcannon at openjdk.org> wrote:
> Hi,
>
> Could someone please review my code for JDK-8254996: 'make jdk.net.UnixDomainPrincipal a record class'?
>
> `jdk.net.UnixDomainPrincipal` is a simple immutable data class that requires boilerplate methods for access. However, these methods and fields are susceptible to trivial mistakes and add to the verbosity of the class.
> This fix replaces the data class with a record class, a new type in JDK 16, making the code more concise and easier to maintain. This code is binary compatible with the original. For the generated API doc change, please refer to the specdiff attached to the CSR.
>
> CSR : https://bugs.openjdk.java.net/browse/JDK-8257823
>
> Kind regards,
> Patrick
This pull request has now been integrated.
Changeset: 6dd06add
Author: Patrick Concannon <pconcannon at openjdk.org>
URL: https://git.openjdk.java.net/jdk/commit/6dd06add
Stats: 52 lines in 1 file changed: 3 ins; 45 del; 4 mod
8254996: make jdk.net.UnixDomainPrincipal a record class
Reviewed-by: dfuchs, michaelm
-------------
PR: https://git.openjdk.java.net/jdk/pull/1668
More information about the net-dev
mailing list