Evaluate: Function evaluates (executes) the groovy script and returns...

Description Usage Arguments Value Examples

Description

Function evaluates (executes) the groovy script and returns the result.

Usage

1
Evaluate(groovyShell = NULL, groovyScript)

Arguments

groovyShell

The groovyShell with which to execute the specified groovy script. Note that the groovyShell can be NULL, however if this is NULL then the Initialize function must have been called so that a global groovyShell instance will be available in the environment otherwise an exception is raised.

groovyScript

The groovy script being executed.

Value

The result of the script execution.

Examples

1
2
3
4
5
 ## Not run: 
 Initialize ()
 Evaluate (groovyScript="print 'Hello world!'")
 
## End(Not run)

rGroovy documentation built on May 1, 2019, 10:28 p.m.

Related to Evaluate in rGroovy...