working on Java translation