Implemented XML loading