Updating java code