protected Object doTopCall ( Callable callable , Context cx , Scriptable scope , Scriptable thisObj , Object [ ] args ) { Object result = callable . call ( cx , scope , thisObj , args ) ; return result instanceof ConsString ? result . toString ( ) : result ; }
Execute top call to script or function . When the runtime is about to execute a script or function that will create the first stack frame with scriptable code it calls this method to perform the real call . In this way execution of any script happens inside this function .