Make compatible with java5