Changed to use Java 7