当前位置:网站首页>Introduction to shortcut keys in debug chapter
Introduction to shortcut keys in debug chapter
2022-07-25 11:32:00 【Dream】
One 、Debug The opening
Take a look first IDEA in Debug Interface in mode . 
Here's how IDEA Start in Debug Pattern , Enter the interface after the breakpoint , I am here Windows, May and Mac The icons of . Let's simply say that 8 A place to :
① With Debug Mode start service , A button on the left Run mode . In development , I usually start it directly Debug Pattern , Easy to debug code at any time .
② The breakpoint : Left click in the left line number bar , Or shortcut key Ctrl+F8 In the play / Cancel breakpoint , The color of breakpoint line can be set by yourself .
③ Debug window : After the access request reaches the first breakpoint , Will be activated automatically Debug window . If not activated automatically , You can set it in the settings , Pictured 1.2.
④ Debug button : Altogether 8 Button , The main functions of debugging correspond to these buttons , Hover over the button to view the corresponding shortcut key . In the menu bar Run You can find the same function in , Pictured 1.4.
⑤ Service button : Can be closed here / Start the service , Set breakpoints, etc .
⑥ Method invocation stack : This shows all the methods that this thread debugs , Check the [Show All Frames] Button , It will not show the methods of other class libraries , Otherwise, there will be a lot of ways .
⑦ Variables: In the variable area, you can view the variables in the current method before the current breakpoint .
⑧ Watches: Check the variable , Can be Variables Drag variables in area to Watches View in
Two 、 Basic usage & Shortcut key
Debug The function of debugging mainly corresponds to that in Figure 1 4 and 5 Two sets of buttons :
1、 Let's start with the first set of buttons , common 8 Button , The sequence from left to right is as follows :
![[ chart 2.1]](/img/d8/2b5c58034f774f146f04a7109b21a6.png)
> Show Execution Point (Alt + F10): If your cursor is on another line or other page , Click this button to jump to the current line of code execution .
> Step Over (F8): Step over , Go down line by line , If there is a method on this line, it will not enter the method .
> Step Into (F7): Stepping into , If the current line has a method , Access to method interior , Generally used to enter the custom method , Methods that will not enter the official class library , As the first 25 Yes put Method .
> Force Step Into (Alt + Shift + F7): Forced entry , Access to any method , You can use this method to enter the official class library when viewing the underlying source code .
> Step Out (Shift + F8): Step out , Exit from the stepped in method to the method call , At this time, the method has been executed , It's just that the assignment hasn't been completed .
> Drop Frame ( The default is no ): Fallback breakpoint , Detailed description in later chapters .
> Run to Cursor (Alt + F9): Run to the cursor , You can position the cursor on the line you want to see , Then use this function , The code runs to the cursor line , Without breaking points .
> Evaluate Expression (Alt + F8): Calculation expression , Detailed description in later chapters .
2、 Second set of buttons , common 7 Button , From top to bottom as follows :

> Rerun ‘xxxx’: Rerun program , Will shut down the service and restart the program .
> Update ‘tech’ application (Ctrl + F5): To update the program , Generally, you can perform this function after your code has been changed . The corresponding operation of this function is in the service configuration , Pictured 2.3.
> Resume Program (F9): Recovery procedure , such as , You are in the 20 Row sum 25 Line has two breakpoints , Currently running to 20 That's ok , Press F9, Run to the next breakpoint ( That is to say 25 That's ok ), Press again F9, Then run the whole process , Because there are no breakpoints .
> Pause Program: Suspend program , Enable Debug. No specific usage found at present .
> Stop ‘xxx’ (Ctrl + F2): Press twice in a row , Shut down the program . Sometimes you will find that when the service is shut down and restarted , Message port occupied , This is because the service is not completely shut down , You need to kill everything JVM Process .
> View Breakpoints (Ctrl + Shift + F8): View all breakpoints , Later chapters will cover .
> Mute Breakpoints: Dumb breakpoint , After choosing this , All breakpoints gray , Breakpoint failure , Press F9 You can run the program directly . Click again on the , Breakpoint turns red , It works . If you want to disable only one breakpoint , You can right-click on the breakpoint to cancel Enabled, Pictured 2.4, Then the line breakpoint is invalid .
边栏推荐
- C# Newtonsoft.Json 高级用法
- SQL注入 Less17(报错注入+子查询)
- Getting started with tensorflow
- SQL injection less23 (filter comment)
- HCIA experiment (06)
- 将字符串转换为数字
- Implementation of recommendation system collaborative filtering in spark
- SQL injection less17 (error injection + subquery)
- Multiply Floyd "suggestions collection"
- Hcip experiment (04)
猜你喜欢

NowCoderTOP1-6——持续更新ing

MySQL | GROUP_ The concat function concatenates the values of a column with commas

新能源销冠宏光MINIEV,有着怎样的产品力?

活动报名 | 玩转 Kubernetes 容器服务提高班正式开营!

SQL language (III)

Understanding: idea uses Scala to write wordcount programs and generate jar packages

Game backpack system, "inventory Pro plug-in", research and learning ----- mom doesn't have to worry that I won't make a backpack anymore (unity3d)

Esp32c3 based on the example tutorial of esp32 Rainmaker development under Arduino framework

推荐系统-协同过滤在Spark中的实现

【电子器件笔记5】二极管参数和选型
随机推荐
Dataframe print ellipsis problem
LVS load balancing lvs-dr builds Web Clusters and LVS combines with kept to build highly available Web Clusters
SQL语言(一)
Only know that the preform is used to generate objects? See how I use unity to generate UI prefabs
[high concurrency] deeply analyze the execution process of worker threads in the thread pool through the source code
NowCoderTOP12-16——持续更新ing
feign客户端请求之LoadBalancerLifecycle生命周期
Nowcodertop1-6 - continuous updating
Details of the list of state products that Apple announced to be eligible for the sales tax holiday in the United States
shell-第八章练习
SQL注入 Less23(过滤注释符)
A troubleshooting record of DirectShow playback problems
Txt to CSV file, blank lines appear every other line
syncronized锁升级的过程
Shell - Chapter 6 exercise
Leetcode sword finger offer 28. symmetric binary tree
小微企业智能名片管理小程序
DNS分离解析的实现方法详解
Learn Luzhi PHP -- tp5.0 uses Chinese as an alias and reports "unsupported data expression"
LVS负载均衡之LVS-DR搭建Web群集与LVS结合Keepalived搭建高可用Web群集