duplicated parser method for xml