As if it wasn’t wearing enough explaining to people that Javascript has nothing to do with Java, the Javascript engine in HP Operations Orchestration (OO) scriplet operations is implemented in RHINO, a Javascript engine written in Java. But, you said…..

Despite this, being able to access Java objects within OO scriplets is quite handy. In fact an OO developer – who shall remain unnamed – described it as the only thing that stopped him going ‘royally insane’ in the clicky clicky world of OO.

Below is an example of fetching the time from the Java Date library and setting it as the scriplet’s output.


var d = new java.util.Date();
var time = d.getTime();
scriptletResult = time;

Simples.