17.7 Java 8 Stream Api Features part 6 Defining methods in Interface using Default Keyword

preview_player
Показать описание


Follow on Facebook:

Subscribe to our other channel:
Telusko Hindi :
Рекомендации по теме
Комментарии
Автор

Hi...I have a question. Like you said, on above video that we can define method in interface that should start with default keyword and then you said it is default public method implicitly. So my question is how method can default and public at the same time??

aditigoyal
Автор

Hi... You said methods that we define in Java 8 are default public. When comes to accessibility of the interface methods which are defined, can we access them in a different package? Becuase methods which are of default cant be accessed in different package

lokeshchitturi
Автор

In Java 8, we can able to define method, then how interface will provide fully abstraction?

akashshinde
Автор

How many times are we allowed to use this default keyword? What if I want to define two or more methods during modification of Interface? Could anyone help ? Thanks a lot!

abhishekdigambarjain