add support for returnformat Java