I'm using java to run a command line utility written in Rhino but if there is an error I need to return that error back to the shell so processing stops. How do I pass back an error code from Rhino to the shell?
How do you return an exit code from Rhino?
Executing java.lang.System.exit(1)
may produce unexpected results such as entire environment or application quitting (e.g. HPOO).
just noting an unexpected behavior as HPOO uses rhino and calling the above will kill the entire studio environment. It won't even bother asking you to save your workflows if there are outstanding changes. –
Montero
I still think this answer should've been a comment on the other answer. –
Disconcerted
© 2022 - 2024 — McMap. All rights reserved.