Implemented an 'import from XML' function.