just the java code