Method references in Java 8
1 Method reference is a shorthand notation of a lambda expression. Which is used to call any method.
2 :: operator is used for Method reference.
Types of Method References
1. Reference to a static method
ContainingClass::staticMethodName
Method reference: NumberChecker::isEven
2. Reference to a constructor
ClassName::new
Person::new
3. Reference to an instance method of an arbitrary object of a particular type
ClassName::instanceMethodName
Person::getName
4. Reference to an instance method of a particular object
containingObject::instanceMethodName
object::instanceMethodName
On this page of the site you can watch the video online Method references in Java 8 with a duration of hours minute second in good quality, which was uploaded by the user javatechstack 08 September 2018, share the link with friends and acquaintances, this video has already been watched 678 times on youtube and it was liked by 4 viewers. Enjoy your viewing!