private static String invokeStringMethod ( final ScriptEngine jsEngine , final Object thiz , final String name , final Object ... args ) throws NoSuchMethodException , ScriptException { return ( String ) ( ( Invocable ) jsEngine ) . invokeMethod ( thiz , name , args ) ; }
Calls a method on a script object compiled during a previous script execution which is retained in the state of the ScriptEngine .