[Contents] [Prev] [Next] [Index] [Report an Error]


jcs:sleep()

Syntax

jcs:sleep(seconds <, millis>)

Description

Cause the script to sleep for a specified period. You can use this function to help determine how a routing component is working over time. To do this, write a script that issues a command, calls the jcs:sleep() function, and reissues the same command. The millis argument is optional.

Usage Examples

In this example, jcs:sleep(1) means one second and jcs:sleep(0, 10) means ten milliseconds.

<xsl:variable name="ignore" select="jcs:sleep(1)"/>
<xsl:variable name="ignore" select="jcs:sleep(0, 10)"/>

jcs:sysctl()

Syntax

jcs:sysctl("expression", "i")

jcs:sysctl("expression", "s")

Description

Return the value of the given expression or object as a string or an integer.

Attributes

i—Specifies an integer.

s—Specifies a string.
Default: s

Usage Example

var $value = jcs:sysctl("kern.hostname", "s");

[Contents] [Prev] [Next] [Index] [Report an Error]