Convert many examples to java backend

**please review**
Right, I expected that to be the reason.  It would be nice though to have a hook to the builtin equality that the internal unification algorithm uses, for those who want to implement things really efficiently.  But this can wait.  It is good to merge.