Given a name element, this function extracts the identifier name from it. A name element may potentially contain several child name elements. For example, when a name has the form [ClassName]::[Identifier]. This function assumes that the last child name element is the desired name, and returns that. If there are no child name elements, the text of the name element is returned.
Thrown if the passed XElement does not represent a name element.