Java 8 || Default method() & Static method() inside Interface by Durga Sir

preview_player
Показать описание
Oracle Java Certification: Shortest Way To Crack OCA 1Z0-808 Just @ Rs 640/-

1. For Java SE 8 Programmer I Exam
2. Topic wise Tests and Grand Tests
3. 280 Realistic Questions With Clear Explanation
4. Study Material (408 Pages)
5. Question Bank (107 Pages)
6. Videos (63 Sessions)

Use the below links to access Durga Sir Videos and Downloadable Materials and Topic wise Tests and Grand Tests with Life-Time Access.

1. Oracle Java Certification: Shortest Way To Crack OCA 1Z0-808

2. Java 8 New Features In Simple Way

3. Java 9 New Features In Simple Way: JShell, JPMS and More

4. Complete JDBC Programming Part-1

5. Complete JDBC Programming Part-2

For More Info:
DURGASOFT Online Team
Ph:8885252627,7207212427/28
Рекомендации по теме
Комментарии
Автор

Only person to call a java class as bloody!!
Thats our Durga Sir!!!

anilarkay
Автор

The Good thing is that Durga sir explaining the concepts should be understood by all the members in the team, not only for one. Salute for your patience sir. Some People take money but won't give such an explanation.

phaneendraphani
Автор

Sir i have been watching your video since 3 months and i can see my confidence has increased after watching you tutorial
Thanks sir keep supporting us

samee.
Автор

Thanks for the tutorial. But I have a small suggestion. Try to provide use of default and static at Java language level...Like for example, the forEach method is a default method available in Iterable interface. So in collection everywhere like for List, Map and Set we can use this forEach method.


How is this possible? Remember Collection is top level interface that all other interfaces like List, Set etc inherit. But Collection interface itself extends Iterable interface..


In Iterable interface, this method def:


default void forEach(Consumer<? super T> action) {

for (T t : this) {
action.accept(t);
}
}

Similarly for static methods, there is a class called Objects.java in java.util package. It has all static methods that are used as utility stuff as sir rightly said in the session.

Some examples.
public static boolean deepEquals(Object a, Object b) {
if (a == b)
return true;
else if (a == null || b == null)
return false;
else
return Arrays.deepEquals0(a, b);
}
public static boolean isNull(Object obj) {
return obj == null;
}
etc.

Something like this is useful for students to understand at language level.

RAMAKRISHNARV
Автор

I am following this channel from last 3 months. Now I am so much confidence in Java Language. Thank you for your valuable tutorial sir.Huge Respect from my side.

sundargautamofficial
Автор

Thanks a lot sir...I have watched complete playlist in a day..I am employee to Virtusa..This Playlist saved my Training..

kingcoachingcenter
Автор

I searched no.of websites videos, but I didn't got why they given static and default method. But after watching your video I can give left and right to anyone. Thanks sir

pmohan
Автор

just started watching your video for attending interviews...U r amazing sir...no words!!!

devulechutalks
Автор

Thank you sir I enjoyed the session a lot first time I got so clear explanation

dikshanavgire
Автор

classes looks bloody classes to Durga sir since java8. :)
Great explanation sir.

hemantkumar-clyp
Автор

I love it .. When u laugh while asking tricky questions 😂😂

muddu
Автор

Please lizen !! Every Concept is the mowst important concept for Durga Sir.

jnanadeepnayak
Автор

Hello Sir, I learnt a lot from you sir. Thank very much. I have a doubt in above video, at 35:16, class Test extends P1, P2. This is actually not possible.Because, compiler will show you compile time error. It will not allow you to go ahead to run the programme as multiple inheritance is not possible in java. So we can't compile the programme further. But you compliled the programme .

hemantn
Автор

You are awesome sir!! The way you explaining the concepts which i taught was difficult but after watching your videos my opinion changed and it is so clear also helpful and finished 4 sessions and i going to finish all of them soon..

sagarpuvvada
Автор

Awesome, 👍

If you require a sweeper then why you go for IAS officer 👌( Static method in Interface )

IndianYakker
Автор

Thank You So Much @Durga_Software_Solutions for the playlist of java 1.8v

BoringDeveloper
Автор

thank you very much sir providing these videos for us

saddamahmad
Автор

I am able to add hashcode method in interface. I did not get any compilation error interface Testinthash1
{
default void m9()
{
System.out.println(" Inside Test int hash method");
}

default int hashcode()
{
return 10;
}

}

public class HashcodeInJava8 implements Testinthash1
{

public static void main(String[] args)
{

DefaultMethodInJava8 t1 = new DefaultMethodInJava8();
t1.m9();


}
}

MahaLakshmi-beqo
Автор

Big fan of your teaching sir.
If possible can you please make a video on how to use Lombok feature.
😘

nandkishorkusalkar
Автор

Hi Sir, you explained very nicely and i like ur all java8 sessions, i have small suggestion given below
java will never implement multiple interface because it strictly following constructor chaining.
i feel diamond problem which you explained is incorrect, because diamond problem will occurs only when your creating child class object, in this case jvm will get ambiguity because jvm dont know which class constructor to call. due to this reason sun people removed this concept from java
i hope i have given good reason please feel free to give a comment on top of my message

ramand
welcome to shbcf.ru