RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
IDOMNode.prefix Property

Indicates the namespace prefix for the node.

Pascal
property prefix: DOMString;
C++
__property DOMString prefix;

Read prefix to determine the namespace prefix for an element or attribute node.  

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

For attribute nodes, prefix is derived from the string that appears to the left of the equals sign in the attribute declaration. For example, with the element <xsi:Name xsi:First=John xsi:Last=Doe>, both attribute nodes have the prefix of 'xsi'. Attribute nodes do not inherit a prefix value from the element node to which they are attached. For example, with the element <xsi:Name First=John Last=Doe>, both attributes have a prefix of nil (Delphi) or NULL (C++). 

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

Note: If the prefix and localName properties are defined for a node, nodeName is the combination of those two values.
Note: prefix is nil (Delphi) or NULL (C++) for nodes created with a DOM level 1 interface such as the document's createElement method, even if they are element or attribute nodes.
 

 

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