Updated the XML schemas and refactored the code accordingly