HowTo Raise an exception during debug
I am working with IntelliJ 6.0 to debug a tomcat server (jboss).
Suppose I (remote) debug some code.
In a certain point I would like to simulate an exception so a specific Exception (Application-Specific Exception not NullPointerException) will be thrown and be caught on some try{}catch() somewhere above (below?) in the call stack.
Is there any way to do it?
Thanks,
Izik
Please sign in to leave a comment.
Hello Izik,
Try evaluating "throw new MyException()" using Alt-F8.
--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
right click on the stack in the debugger/stack view.
there is a option "Throw Exception"