Backward compatibility with JDK 7