8308960: Decouple internal Version and OperatingSystem classes

Reviewed-by: mchung
This commit is contained in:
Roger Riggs 2023-05-30 17:07:02 +00:00
parent 1b8e6bf31c
commit 323d6ceda6
5 changed files with 59 additions and 65 deletions

View file

@ -28,14 +28,13 @@ package jdk.internal.loader;
import java.io.File;
import java.util.ArrayList;
import jdk.internal.util.OperatingSystem;
import jdk.internal.util.Version;
import jdk.internal.util.OSVersion;
class ClassLoaderHelper {
// SDK 10.15 and earlier always reports 10.16 instead of 11.x.x
private static final boolean hasDynamicLoaderCache = OperatingSystem.version()
.compareTo(new Version(10, 16)) >= 0;
private static final boolean hasDynamicLoaderCache = OSVersion.current()
.compareTo(new OSVersion(10, 16)) >= 0;
private ClassLoaderHelper() {}