Fix Java 7 compilation