adding XML-related changes based on julian's review