Adding metadata to xml file, and making the xmlReader functionional