Internal utility classes reimplemented for Java 9 and later versions.