Skillfully debug with Eclipse Java Editor

Source: Internet
Author: User
Tags java web
When you use eclipse to develop a Java Web application, the editor will not only provide developers with common functions such as code writing, auxiliary hints, and real-time compilation, but also enable advanced operations such as quick modification, refactoring, and syntax correction for Java source code. Through the Eclipse Java Editor, we can easily find some grammatical errors, and follow the prompts for quick correction, but also convenient. The debugging capabilities provided by the Eclipse Java Editor are described below.

1. Error prompt
At the far left of the line of code where the error occurred, to indicate where the error is located, move the mouse over the tag, and the specific error message is displayed, 1.7 shows the specific error message that is displayed when the variable is undefined.

Figure 1.7 Specific error messages

2. Red wavy lines below the code
Below the code where the error appears, a wavy red line appears, moving the mouse over the red wavy line, which shows the available quick fixes (shown in example 1.8), and clicking on the specific hyperlink to make a quick fix error.

Figure 1.8 The Quick fix prompt box available

3. Markup in the upper-right corner of the editor window
Its role is to prompt the developer that there is an error somewhere in the document, move the mouse over the icon, and the number of specific errors will be displayed, as shown in 1.9.

Figure 1.9 shows the number of specific errors

4. Markup on the right side of the editor window
In the blank position on the right side of the editor, you can see one or more red rectangles that indicate the approximate position of the line where the error is located, and if the code is very large, you can click the red rectangle block to quickly locate the row of the error.

5. The Issues panel
In the bottom middle of eclipse, there is a "markers" panel, in which errors or warnings appear in the project in tabular form. Figure 1.10 is a "markers" panel that includes 16 errors.

Figure 1.10 "Markers" panel

Skillfully debug with Eclipse Java Editor

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.