In Oracle Integration Cloud (OIC) XSLT, the XPath function self::node()
is used to reference the current node in a predicate or expression.
Purpose of self::node()
It ensures that the comparison or operation is being done on the current node itself, rather than its child or attribute.
Example Usage in OIC
In your expression:
fn:count(ns95:dtstart[(self::node() = $FileProcessingDate)])
Here:
self::node()
refers to the value of the currentdtstart
element.- It compares that value directly to
$FileProcessingDate
.
Why use self::node()
?
While .
(dot) also refers to the current node, self::node()
is more explicit and avoids ambiguity in complex expressions, especially when namespaces or deeper hierarchies are involved in OIC mappings.
Simplified Equivalent
This:
self::node() = $FileProcessingDate
Is functionally equivalent to:
. = $FileProcessingDate
But self::node()
is sometimes preferred in tools like OIC for clarity or compatibility.
No comments:
Post a Comment