Ported most of the XMLtype system to the new string class