Pathfinder Applications
Note: † Internal applications are hidden from customers and partners. This is visible to you because you have logged into HPEs internal network.
Navigation
Table of Contents
Guide That Contains This Content
[+] Expand All
[-] Collapse All
Related Documentation
- ACX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- EX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- M Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- MX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- PTX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- SRX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- T Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
empty() Function (jcs and slax Namespaces)
Namespaces
http://xml.juniper.net/junos/commit-scripts/1.0http://xml.libslax.org/slax
SLAX Syntax
var $result = prefix:empty(node-set | string);
XSLT Syntax
<xsl:variable name="result" select="prefix:empty(node-set | string)"/>
Release Information
Function introduced in Junos OS Release 7.6
Support for the slax namespace http://xml.libslax.org/slax added in Junos OS Release 12.2.
Description
Test for the presence of a value and return true if the node set or string argument evaluates to an empty value.
The prefix associated with the namespace URI should be defined in the prefix-to-namespace mapping in the style sheet.
Parameters
(node-set | string) | — | Argument to test for the presence of a value. |
Return Value
result | — | Boolean value, which is true if the argument is empty. |
Usage Examples
In the following example, if $set is empty, the script executes the enclosed code block:
if ( jcs:empty($set) ) {
/* Code to handle true value ($set is empty) */
}The following example tests whether the description node for interface fe-/0/0/0 is empty. If the description is missing, a <message> tag is output.
if (jcs:empty(interfaces/interface[name="fe-0/0/0"]/description)) {
<message> "interface " _ name _ " is missing description";
}Related Documentation
- ACX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- EX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- M Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- MX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- PTX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- SRX Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)
- T Series
- Summary of Extension Functions in the jcs and slax Namespaces
- Junos Script Automation: Understanding Extension Functions in the jcs and slax Namespaces
- first-of() Function (jcs and slax Namespaces)