Convert to more modern Java.