#2 Added support for java7