java support for multiple dataset types, bugfixes