Тёмный

Java 8 Streams | Exception Handling Mechanism | lambda | JavaTechie 

Java Techie
Подписаться 166 тыс.
Просмотров 66 тыс.
50% 1

In this tutorial Here, I’d like to discuss a few of the things I’ve learned over time in handling exceptions within lambdas. Keep in mind, there are always multiple approaches to things like this, so take this with a pinch of salt. If you think there are better ways to do the things below, please do let me know.in upcoming tutorial
#javatechie #JavaStream #Exception #java8
GitHub:
github.com/Java-Techie-jt/java8
Blogs:
/ javatechie4u
Facebook:
/ 919464521471923
guys if you like this video please do subscribe now and press the bell icon to not miss any update from Java Techie
Disclaimer/Policy:
--------------------------------
Note : All uploaded content in this channel is mine and its not copied from any community , you are free to use source code from above mentioned GitHub account

Наука

Опубликовано:

 

16 июл 2021

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 66   
@abhijitprusty
@abhijitprusty 2 года назад
NEver seen any video explaining this kind of exception handling with lambda, which is really awesome
@ArshadMansuri-gb1so
@ArshadMansuri-gb1so 7 дней назад
I have learned lot of concept by your Chanel and keep learning thanks a lot.
@robertstan6108
@robertstan6108 2 года назад
Incredible knowledge
@shrijeetkumarpanda5325
@shrijeetkumarpanda5325 2 года назад
Great way to start Sunday with awesome concept.. dhanyabad bada bhaii
@80pawangupta
@80pawangupta Год назад
I have been working in technical line for many years for now and I find your videos very detailed and full of concepts
@Javatechie
@Javatechie Год назад
Thanks Pawan keep learning 😃
@neha6000
@neha6000 Год назад
Thank you for this much great explanation
@jpssasadara3624
@jpssasadara3624 Год назад
the best content which i show, thank! keep it up
@ravindusamaranayake3278
@ravindusamaranayake3278 2 года назад
Great job, Thanks!
@priyankjoshi3018
@priyankjoshi3018 2 года назад
Nice one, keep it up.
@rajenderprasad1193
@rajenderprasad1193 2 года назад
Always with best content and explanation. Thank you so much
@Javatechie
@Javatechie 2 года назад
Thanks Rajendra 😊
@nameshd658
@nameshd658 2 года назад
Thanks, Brother. All the best.
@nitinkale8102
@nitinkale8102 2 года назад
Great job
@Ashrafkhan-mp7eo
@Ashrafkhan-mp7eo 2 года назад
Awesome tutorial pls make multithreading interview questions and answer
@arunkumarjena18
@arunkumarjena18 2 года назад
Awesome.
@husnainajmal3346
@husnainajmal3346 2 года назад
incredible
@pratishrutipanda6461
@pratishrutipanda6461 2 года назад
No one can explain this better than you
@josephnairpudupermanil8679
@josephnairpudupermanil8679 2 года назад
Awesome explanation
@shivsagarsingh2466
@shivsagarsingh2466 Год назад
best content in java8. Please make videos on design Patterns
@sandhyamachani8720
@sandhyamachani8720 2 года назад
Good explanation
@chandramanigupta6997
@chandramanigupta6997 2 года назад
Great
@duparcg
@duparcg 2 года назад
You are the best . We are still waiting on spring batch complete Tutorial.
@Javatechie
@Javatechie 2 года назад
Spring batch tutorial is there please check in my spring boot playlist
@suryanarayanan8807
@suryanarayanan8807 Год назад
Hi Sir Great explanation. I have a doubt. Using the functional interface handlecheckedexceptionconsumer you are getting Exception as argument and throwing runtime exception in the implementation. So it must be "handle Unchecked Exception Consumer " right?
@akbalkhan5171
@akbalkhan5171 2 года назад
Hi Can you explain about double braces initialization inside a enum and how can I do other way of initialization of it .
@user1994gms
@user1994gms 2 года назад
can I know wch company do u work? great skills with good explanation
@shrijeetkumarpanda5325
@shrijeetkumarpanda5325 2 года назад
Congratulations... for 50K subscribers bhai .. Need a special video
@Javatechie
@Javatechie 2 года назад
Thanks buddy 😊
@mdrashidalam5282
@mdrashidalam5282 2 года назад
Sir please explain memory level and garbage collector video in java 8 and below java8 different in deapth.
@abdurmuneer2969
@abdurmuneer2969 2 года назад
Hello guys my name is abdul i am from India .first of all thank you Basir sir for your videos it is really helpful for peoples like me .Big salute for this.And then i am searching some onsite opportunities working on other country like america,Australia,England or Canada os very bog dream for me.please help me to achieve my dream i am fullstack developer in java and angular.please help me brothers
@kajaraja100
@kajaraja100 2 года назад
Hi Please make the core java basics video. Its helpful for interview preparation
@Javatechie
@Javatechie 2 года назад
I have already uploaded core java basics interview question . please check once
@funnyvideorocks
@funnyvideorocks 2 года назад
Sir no one can teach us proper concept which is reuired for mnc companies....and u are so good ...you teach us proper way ...sir.......can u teach us spring from first sir.?...we are ready to learn from u ...and also can u start from spring mvc?
@Javatechie
@Javatechie 2 года назад
I planned this to start a free batch for spring boot . Will let you know
@funnyvideorocks
@funnyvideorocks 2 года назад
@@Javatechie ok sir ...i have problem with spring boot starter project ..i got error first line of pom.xml. and also there is a msg this is maven plugin error ...how can i solve this problem ...can u tell me
@Javatechie
@Javatechie 2 года назад
Do a Maven update once
@narayancse
@narayancse 7 месяцев назад
I have one question: What is the obj variable in handleExceptionIfAny method? Where is it defined?
@anishfox7719
@anishfox7719 11 месяцев назад
could some one explain this return obj -> { try { }} here type is obj is undefined right?
@sreddy8141
@sreddy8141 2 года назад
Hi sir, could u pls make video on date and time stamp updates in java 8 and also pls teach us ds and algo in java
@Javatechie
@Javatechie 2 года назад
Good content yes I will check and prepare soon
@sreddy8141
@sreddy8141 2 года назад
@@Javatechie thanks a lot sir
@saikumargamingchannel657
@saikumargamingchannel657 4 месяца назад
while returning consumer you are using lambda but it is also taking lot of code inside lambda expression right.
@Javatechie
@Javatechie 4 месяца назад
Yes that's the only option to play with lambda error handling
@technoenter2637
@technoenter2637 2 года назад
Bro is it possible escape security in gateway? Not gateway api’s we have some a, b, c services I need to escape some url in gateway. Is it possible? Any idea? Could you please helm me
@Javatechie
@Javatechie 2 года назад
Yes you can specify ant matchers pattern to bypass url
@technoenter2637
@technoenter2637 2 года назад
@@Javatechie we are bypassing through property file, but antmachers in security config right? So did u meant what all url we need to escape that all give in the gateway security config antmatchers right?
@sairamvemula7887
@sairamvemula7887 2 года назад
Sir, please clarify my doubt, am a bit confused, return type of the method is Consumer I understand, but what is Could someone please explain ?
@Javatechie
@Javatechie 2 года назад
Sairam it's just Exacption class and I used here type generic
@saikumargamingchannel657
@saikumargamingchannel657 4 месяца назад
we cannot use generics in static method.In order to do that we have to declare those type parameter like that so they act as static.
@girishchaudhari4668
@girishchaudhari4668 2 года назад
Please increase audio volume
@arpitjain8990
@arpitjain8990 2 года назад
Why it returns Consumer when supplier return type is void
@Javatechie
@Javatechie 2 года назад
We don't want to return anything from here just wanted to map exception that's why used consumer
@rahulshrirao575
@rahulshrirao575 Год назад
Hi,can you give solution on this coding String nameData = "1:Raja#6:Raman#5:Kabeer#9:Dinesh"; String ageData = "6:35#1:22#5:29#9:77"; Objective : First String contians primary key & Name while Iist String has primary key & Age data. you need to print it like : Raja age is 22 Kabeer age is 29 Ramana age is 35 Dinesh Age is 77
@arjun-fl5eh
@arjun-fl5eh Год назад
Use hash map. Put name data in hash map as primary key as key and name as value. Then iterate through age data and check in names hashmap using primary key and print it if it’s there. Use split method to separate the strings based on character #
@HimanshuSharma-vp8xi
@HimanshuSharma-vp8xi 2 года назад
what is target and exobj here?
@Javatechie
@Javatechie 2 года назад
Target is your input parameter and exobj is exception type
@KimmoKLo
@KimmoKLo 2 года назад
Well, OK, but the title was Stream API and the examples were list.forEach (which is not the Stream API). You could have done something similar with the stream API, but it’s not so simple as you have to return something useful e.g. for the map operation.
@Javatechie
@Javatechie 2 года назад
I didn't find difficulty in map since it takes an argument function I can create a exception handler who return and accept a function
@KimmoKLo
@KimmoKLo 2 года назад
@@Javatechie what would you return after you’ve suppressed the exception?
@Aditya-yn5lk
@Aditya-yn5lk 2 года назад
if we have to fail fast, then we can use map else if we need to handle Exception, then we can use forEach.
@vikashgaurav4126
@vikashgaurav4126 Год назад
​@@KimmoKLo If there is exception then exception is thrown . If everything goes good then it would return Stream. Ex - > Given List using map( n -> divideByZero(n/0,ArithmeticException.class)). Stream divideByZero(Function fn,Class excObjectClass){ return Stream.of(num) -> { try{ fn.apply(num); }catch(Exception ex){ try{ ExcObj exObj = excObjectClass).cast(ex); sout(ex.getMessage); }catch(ClassCastException e) { throw e; } @Javatechie ! Correct me please If I am wrong this is my understanding. Thanks.
@henrivalencia21
@henrivalencia21 2 года назад
dislikes are from the lower java version users
@SuperHuman748
@SuperHuman748 29 дней назад
Generic way of handling exceptions in java 8 using streams
@umesh6747
@umesh6747 8 месяцев назад
Please change title.. you haven't used Streams at all.
@Javatechie
@Javatechie 8 месяцев назад
I believe you haven't watched the complete video
Далее
Java Streams: Beyond The Basics
49:21
Просмотров 71 тыс.
Optionals In Java - Simple Tutorial
15:53
Просмотров 192 тыс.
Lambda Expressions in Java - Full Simple Tutorial
13:05
POV: Cuando compras una TARJETA GRÁFICA al AZAR 😂
0:16
ПК с Авито за 3000р
0:58
Просмотров 876 тыс.
Вы поможете украсть ваш iPhone
0:56