Flashcards
Interfaces
Flashcards do conjunto (6)
- 1Interfaces What is the key word that a class calls to reference an interface?implements
- 2Interfaces All of the classes that implement an interface, including the interface itself must have what?A method that has the same name in every class
- 3Interfaces In the classes that are implementing the interface, what do they have in the method that is uniform to every class implementing the interface?It must call another method in that same class which will actually perform a function
(Essentially, it will be a "this.nameOfMethod") - 4Interfaces Create and implement an interface as though you were doing so in the main method...IPest pest1 = new Housefly();
IPest pest2 = new Telesales(); - 5Interfaces What are the benefits of interfaces? Easy to add a new _____ that implements the interface; saves on _____ and helps with _____Easy to add a new class that implements the interface; saves on programming and helps with maintenance
- 6Interfaces How many methods can you call in the uniform interface method in a foreign class?Infinite
Informações
- Descrição
- Masters of Science Programming 2 FlashCards sobre Interfaces, criado por Nathan Hunsdale em 31-05-2014.
- Criado por
- Nathan Hunsdale
- Visualizações
- 23
- Avaliação