in Education by

What are static default methods in Java8?

Please log in or register to answer this question.

1 Answer

0 votes
by

What are static default methods in Java8? An interface can also have static helper methods from Java 8 onwards. public interface vehicle { default void print() { System.out.println("I am a vehicle!"); } static void blowHorn() { System.out.println("Blowing horn!!!"); } }

Related questions

0 votes
asked Nov 8, 2020 in Education by Editorial Staff
0 votes
asked Nov 19, 2020 in Education by Editorial Staff
0 votes
asked Dec 30, 2020 in Technology by JackTerrance
...