5.5

Table Of Contents
Table 22. Color Coding of Scripting Keywords (Continued)
Keyword Type Text Color in Scripting Tab
Output text Green
Workflow attributes Pink
Workflow inputs Pink
Workflow outputs Pink
Add Parameters to Scripts
The Orchestrator scripting engine helps you to import available parameters into scripts.
If you have already defined parameters for the element you are editing, they appear as links in the Scripting
tab toolbar.
Prerequisites
A scripted element is open for editing and its Scripting tab is open.
Procedure
1 Move the cursor to the appropriate position in a script in the scripting pad of the Scripting tab.
2 Click the parameter link in the Scripting tab toolbar.
Orchestrator inserts the parameter at the position of the cursor.
3 Insert a parameter with a null value into the script.
If you pass null values to primitive types such as integers, Booleans, and Strings, the Orchestrator
scripting API automatically sets the default value for this argument.
You added parameters to the script.
What to do next
Add access to Java classes in scripts.
Accessing the Orchestrator Server File System from JavaScript and Workflows
Orchestrator limits access to the Orchestrator server file system from JavaScript and Workflows to specific
directories.
JavaScript functions and workflows only have read, write, and execute permission in the permanent
directory c:\orchestrator.
The Orchestrator administrator can modify the folders to which JavaScript functions and workflows have
read, write, and execute access by setting a system property. See Installing and Configuring VMware vCenter
Orchestrator for information about setting system properties.
JavaScript functions and workflows also have read, write, and execute permission in the server system
default temporary I/O folder. Writing to the default temporary I/O folder is the only portable, guaranteed,
and configuration-independent means of accessing the file system with full permissions. However, files that
you write to the temporary I/O folder are lost when you reboot the server.
You obtain the default temporary I/O folder by calling the System.getTempDirectory method in JavaScript
functions.
Chapter 2 Scripting
VMware, Inc. 129