Eclipse Usage Tips Compilation

Source: Internet
Author: User

    • Modify Eclipse Default JDK

"Window"---"Preferences ..." (preferences), and then on the left side of the dialog box that pops up: Select Java---installed JREs to add and modify the JDK on the right

    • Why is a lambda expression not supported for a version with more than jdk1.8 installed?

Because the current eclipse version is too low, to support lambda expressions, you also need to install the IDE that supports lambda expression, the best version is to download the latest version of Eclipse, see the official Java documentation for details http://www.oracle.com/ Technetwork/cn/articles/java/lambda-1984522-zhs.html

    • Gets the currently executing function name, class name, and file name of the current class

Current function Name: Thread.CurrentThread (). Getstacktrace () [1].getmethodname ();

Current class Name: Thread.CurrentThread (). Getstacktrace () [2].getclassname ();

Current file name: Thread.CurrentThread (). Getstacktrace () [2].getfilename ();

    • Single-Step debugging

(F5) Step execution procedure, enter when encountering method;
(F6) One step to execute the program, the method is encountered when skipping;
(F7) stepping through the program, jumping out of the current method;
(F8) executes the program directly. Pauses when a breakpoint is encountered;

According to F5 is a layer of depth of debug equivalent to Peel onion samples, will enter each method inside;
Pressing F6 is a step-by-step debug in the current function, ignoring the deep-seated operation;
Pressing F7 is if you are currently inside a method, jump to the end code of the method;
Press F8 is if there is a breakpoint at the back, run to the next breakpoint, or run out of program;

Eclipse Usage Tips Compilation

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.