Fix missing method for java 1.6