Difference (XmlNodelist function): Difference between revisions

From m204wiki
Jump to navigation Jump to search
mNo edit summary
 
mNo edit summary
Line 1: Line 1:
<span style="font-size:120%; color:black"><b>Difference between XmlNodelists</b></span>
{{Template:XmlNodelist:Difference subtitle}}
[[Category:XmlNodelist methods|Difference function]]
[[Category:XmlNodelist methods|Difference function]]
[[Category:XmlDoc API methods]]
[[Category:XmlDoc API methods]]
Line 11: Line 11:
This function creates an XmlNodelist that is the difference of
This function creates an XmlNodelist that is the difference of
(that is, it removes nodes from) one XmlNodelist and another.
(that is, it removes nodes from) one XmlNodelist and another.
===Syntax===
==Syntax==
  %nlis = inNlis:Difference(inNlis2)
{{Template:XmlNodelist:Difference syntax}}
 
===Syntax terms===
====Syntax Terms====
<dl>
<dl>
<dt>%nlis
<dt>%nlis
Line 26: Line 25:
</dl>
</dl>


===Usage Notes===
==Usage notes==
<ul>
<ul>
<li>Difference only affects the nodes created on <i>nlis</i>;
<li>Difference only affects the nodes created on <i>nlis</i>;
Line 41: Line 40:


Another example that makes use of the Difference method is
Another example that makes use of the Difference method is
in the &ldquo;Examples&rdquo; section in [[SelectNodes (XmlDoc/XmlNode function)|SelectNodes]]
in the "Examples" section in [[SelectNodes (XmlDoc/XmlNode function)|SelectNodes]]


===Request-Cancellation Errors===
===Request-Cancellation Errors===

Revision as of 17:52, 22 January 2011

Difference between XmlNodelists (XmlNodelist class)

Difference is a member of the XmlNodelist class.

This function creates an XmlNodelist that is the difference of (that is, it removes nodes from) one XmlNodelist and another.

Syntax

%diffNodl = nodl:Difference( removeNodl)

Syntax terms

%nlis
An XmlNodelist that is set to point to the nodelist that is created.
inNlis
An XmlNodelist.
inNlis2
An XmlNodelist; nodes on this nodelist are removed from inNlis to create the result.

Usage notes

  • Difference only affects the nodes created on nlis; it does not modify the XmlDoc, inNlis, nor inNlis2.
  • The XmlDoc associated with inNlis and nr must be the same.

Example

The following example will create an empty XmlNodelist:

    %empty = %nlis:Difference(%nlis)

Another example that makes use of the Difference method is in the "Examples" section in SelectNodes

Request-Cancellation Errors

  • The XmlDocs associated with inNlis and inNlis2 are not the same.
  • Insufficient free space exists in CCATEMP.

.if 1 = 0 .do

If you want to select nodes in a XmlDoc and remove them from a nodelist, see ?? refid=$xmrmv..

See also ?? refid=$xmplcl.. .do end