Skip to main content

Built-in Global Functions

Jactl provides a number of built-in global functions.

print

The print function prints its arguments to the console.

println

The println function prints its arguments to the console, followed by a newline.

sprintf

The sprintf function formats a string according to a format specifier.

nextLine

The nextLine function reads a line of input from the console.

stream

The stream function creates a stream from a collection.

nanoTime

The nanoTime function returns the current value of the system's high-resolution time source, in nanoseconds.

sleep

The sleep function suspends the current thread for a specified number of milliseconds.

checkpoint

The checkpoint function saves the current state of the script.