Java 8 - Streams filter APIs Examples

preview_player
Показать описание
In this video, I have explained how to use streams with filter in Java 8.

I have explained the use of filter with predict conditions to filter the data from streams and then how to collect the data in the form of List.

~~~Subscribe to this channel, and press bell icon to get some interesting videos on Selenium and Automation:

Follow me on my Facebook Page:

Let's join our Automation community for some amazing knowledge sharing and group discussion on Telegram:

Paid courses (Recorded) videos:
Рекомендации по теме
Комментарии
Автор

I was wondering how to get started with Java Streams. And this video popped up in my watchlist. And, as always you have imparted your knowledge so effortlessly. Thanks a lot.

parthapramanik
Автор

one of the best video on Streams, I saw many videos none could explain as simple as you did. thanks for making this video. I am loving it :)

vandanabanny
Автор

It's a rapid fire of knowledgeable videos coming in :)

shobhit
Автор

Thanks Naveen for awesome Knowledge sharing session.
how can we sort the customer list according to age of customer Can you explain that in next video

VipinDahiya
Автор

Also can create one predicate and use it

List <String> list = Arrays.asList("Phone", "TV", "Couch", "Bike", "Car");

Predicate <String> fun2 = x-> x!="Bike";

List <String> filterData



ankitshrivastava
Автор

Thank you Naveen .. Soon expecting Interview Questions - Part 6 :)

vijayaraghavanvashudevan
Автор

Thanks Naveen.... Shared some great examples.
I was wondering if anyone can help me in regards to below query:
I was trying to create a Generic Method which will take List<T> as one argument and String data_to_filter as another. The reason why I taking List as Generic so that I can use simple method with variance of different Model Class Objects for my different pages.
But I am struggling to convert Predicate into Lambda Expression.

public static <T> List<T> genericList, String dataFilter){
Stream<List<T>> list = {
if(eachListObj instanceof Employee){
super T>) new Predicate<Employee>() {
boolean test(Employee eachEmpObj) {



}else if(eachListObj instanceof Customer){
super T>) new Predicate<Customer>(){
boolean test(Customer eachCust) {



}
return null;
});
return list.findAny().get();
}
This might help someone else as well.
Help is much appreciated.

arkaimps
Автор

Is this map is not related with collection class map?
Can we use hashmap or hashset with stream ?

Swarno
Автор

Using stream can we check if the content exists in a web table clicking on pgination?

gopalmukkamala
Автор

Ur video, in my mobile SamsungGalaxyM57 not visible ...it's blur

gowrujaya
Автор

How we accept the data from the keyboard instead of hard-coded values

pratikkhodke
Автор

Where exactly we will use this Stream api? Can you pls explain in real scenarios?

Manashaist
Автор

what is the difference between filer and map?

swatiwhaval
Автор

i am not yet comfortable with method referance will you please provide something so I understand things behind the screen. I don't want to follow the instruction I need to know deeply for better understanding and for the Intrest of learning.

jatinsharma