Definition of java8 function expression [definition of a LAMBDA expression]

Source: Internet
Author: User

English from: Java In a nutshell, 6th Edition

Definition of a Lambda Expression
A lambda expression is essentially a function of does not having a name, and can be
Treated as a value in the language. As Java does not allow code to run around in its
Own outside of classes, in Java, this means, a lambda was an anonymous method
That's defined on some class (that's possibly unknown to the developer).
-java In a nutshell, 6th Edition

In fact, a regular expression is a function without a name (parameter, return value, function body), which is considered a value in the Java language.
Because Java functions must be defined in a class, this means that a function expression in the Java language is an anonymous method defined in a class.

The function expression is treated as a value in Java, that is: Runnable r = (), System.out.println ("Hello World"); Form

Definition of java8 function expression [definition of a LAMBDA expression]

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.