Convert many examples to java backend

**do not review yet**
This is easy enough to fix. I will take care of it.