Detailed use of Debug in Eclipse

1. Set a breakpoint
Double-click the line with the left mouse button to hit the next breakpoint, and double-click to cancel it.
Note: You can set multiple breakpoints
Insert picture description here
2.debug as java application
Click the right mouse button, as shown in the figure.
Insert picture description here
3. Common operations
Here are several commands commonly used in debug, as shown in the following table:
Insert picture description here

operating effect
step into (f5) Enter the currently called method
step over skip (f6) After executing the statement in the current line, go to the next line
step return (f7) After executing the method in the current line, go to the next line
drop to frame Go back to the first line of the method where the current line is
resume resume After executing all the code at the breakpoint of the current line, enter the next breakpoint, if not, end

Guess you like

Origin blog.csdn.net/weixin_43553142/article/details/105588199