RFR: 8374727: Audio configuration Platform class - use nio for getting endianness of the underlying platform [v2]

Matthias Baesken mbaesken at openjdk.org
Mon Jan 12 08:06:40 UTC 2026


On Mon, 12 Jan 2026 06:31:03 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:

>> Matthias Baesken has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Simplify isBigEndian
>
> src/java.desktop/share/classes/com/sun/media/sound/Platform.java line 63:
> 
>> 61:      */
>> 62:     static boolean isBigEndian() {
>> 63:         return java.nio.ByteOrder.nativeOrder().equals(java.nio.ByteOrder.BIG_ENDIAN);
> 
> what is a purpose to use fqdn for ByteOrder class here?

Just checked how other JDK coding is doing the LE/BE test, then copied it from here
https://github.com/openjdk/jdk/blob/7cf7f01fb339bf3c5b81d946be8afa71ec267e42/src/java.security.jgss/share/classes/sun/security/krb5/internal/util/KrbDataInputStream.java#L49
Should I instead import `java.nio.ByteOrder`  ?

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

PR Review Comment: https://git.openjdk.org/jdk/pull/29113#discussion_r2681201247


More information about the client-libs-dev mailing list