RXS_XPath()
This subprocedure assists with building an XPath string. This is recommended over simply manually building an XPath string.
In addition to providing an easy way to include numeric replacement values, it also allows for including a wildcard namespace. The wildcard namespace syntax is translated to its’ XPath 1.0 equivalent and returned along with any replacements that were passed.
Subprocedure Prototype
|
Returns the constructed XPath string. |
|
Holds the initial XPath string template |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
|
Holds a numeric replacement value. Replaces the first unreplaced %u found in the XPath string template. |
Example Code
*--------------------------------------------------------------
* This example code demonstrates creating an XPath that can be used for
* further processing.
*--------------------------------------------------------------
H DFTACTGRP(*NO) BNDDIR('RXSBND') ACTGRP(*CALLER)
/copy QRPGLECPY,RXSCB
D gXPath S Like(RXS_Var1Kv_t)
/free
gXPath = RXS_XPath( '/*:bookstore/*:book' );
*INLR = *ON;
/end-free