RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
TXMLNode.GetLocalName Method

Returns the name of the node without any namespace prefix.

Pascal
function GetLocalName: DOMString;
C++
__fastcall DOMString GetLocalName();

Use the TXMLNode object's IXMLNode interface to call the protected GetLocalName method. GetLocalName returns the local name of the underlying DOM node. 

For element nodes, the local name is derived from the name that appears in the XML tag. For example, the local name for <xsi:Name First="John" Last="Doe"> is 'Name'. 

For attribute nodes, the local name is derived from the string that appears to the left of the equals sign in the attribute declaration. For example the element <Name First=John Last=Doe> results in two attribute nodes, with the local names 'First' and 'Last'. 

For any other node types, the local name is nil (Delphi) or NULL (C++).

Note: If both GetPrefix and GetLocalName return a value for a node, the node name (returned by GetNodeName) is the combination of these two values.
 

 

Copyright(C) 2009 Embarcadero Technologies, Inc. All Rights Reserved.
What do you think about this topic? Send feedback!