Refactor XmlPropertyTask.

I'm doing an extended version of XmlPropertyTask that saves the result to disk instead of adding the properties to the project. It would benefit a lot from this little refactoring.