Java rewrite engine

Should still be SimpleType here.