#9 - Java 8 - Functional Interfaces Practice Java 8

Pubblicato il: 16 settembre 2022
sul canale di: Lazy Programmer
451
22

Hello Everyone,

In this video we'll see what are functional interfaces and also see few built in functional interfaces provided in Java 8. This session is mainly Practice Session with examples of all the discussed Functional Interface.

0:00 Introduction
0:29 Predicate Functional Interface : To check if a number is even
3:05 Function Functional Interface : To double a number
4:30 UnaryOperator Functional Interface : Update a value
6:20 BinaryOperator Functional Interface : Multiply two numbers
8:00 Supplier Functional Interface : Supply current LocalDateTime value
9:56 Consumer Functional Interface : Consume a list and print its contents


Java interview questions and answers

To check out more on the tutorials Topic wise you can follow below links

Links:

Please do checkout other tutorial videos also if required:

Java 8 Features:    • Java 8  

Core Java Complete Tutorial:    • Core Java Complete Guide  

Interview Preparation for Java:    • Interview Preparation Java  

Python:    • Python  

Linux:    • Linux  

Please do LIKE, Share and SUBSCRIBE

Thank You

Functional interfaces are included in Java SE 8 with Lambda expressions and Method references in order to make code more readable, clean, and straightforward. Functional interfaces are interfaces that ensure that they include precisely only one abstract method. Functional interfaces are used and executed by representing the interface with an annotation called @FunctionalInterface. As described earlier, functional interfaces can contain only one abstract method. However, they can include any quantity of default and static methods.

In Functional interfaces, there is no need to use the abstract keyword as it is optional to use the abstract keyword because, by default, the method defined inside the interface is abstract only. We can also call Lambda expressions as the instance of functional interface.

Before Java 8, we had to create anonymous inner class objects or implement these interfaces.

#java8 #streamapi #stream #interview #multithreadinginjava #hashmap #hashtable #interview #jdbc #java #db #treeset #collectionframework #binarysearchtree #linkedlist #list #arraylist #fibonacci #java #fastest #gc #heap #java #stack #jvm #architecture #exception #interview #exam #interface #abstraction #coding #methodoverloading #methodoverriding #runtime #compiletime #polymorphism #inheritance #constructors #objects #static #eclipse #developer #installation #download #awesome #youtube #youtuber #youtubers #subscribe #youtubevideos #sub #youtubevideo #like #identifiers #operators #variables #typesofvariables #innerclasses #static


In questa pagina del sito puoi guardare il video online #9 - Java 8 - Functional Interfaces Practice Java 8 della durata di ore minuti seconda in buona qualità , che l'utente ha caricato Lazy Programmer 16 settembre 2022, condividi il link con amici e conoscenti, su youtube questo video è già stato visto 451 volte e gli è piaciuto 22 spettatori. Buona visione!