Java – put a breakpoint on each line of eclipse?

Is there a way to set breakpoints on every line in eclipse?

The reason I ask is because I'm analyzing a proxy program written in Java that waits and listens for connections I try to understand how it works, but I can't figure out the origin of the code when the connection arrives

No matter where the code starts, in other words, every line has a breakpoint. How can I trigger the breakpoint?

Solution

I can't figure out why you want breakpoints in every line This is equivalent to simply placing a breakpoint on the first line of main () and stepping into your program - not what a rational person usually wants to do with a large program

I would suggest:

>Delete or disable any breakpoints you already have > start the agent in debug mode; Allow it to initialize Listening now. > Click the "pause" button in the debugging control You may have to choose the correct thread pause – experiment. > Look at the stack display, which shows where it paused It may pause in the library class – following the stack to your own code

If you like, you can now use the client to connect to the proxy and use the debug step control to see how the code handles it One problem with this is that things time out when you look at the steps, so it's useful to set a longer timeout when possible

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>