Large updates to the SnakeModel and some new tricks to java_file