Convenient function to initialize, at construction time, a GXml.Element using given local name and document.