I have seen this mentioned a few times and I am not clear on what it means. When and why would you do this? I know what interfaces do, but the fact I am not clear on this makes me think I am missing...
I have had recently two telephone interviews where I've been asked about the differences between an Interface and an Abstract class. I have explained every aspect of them I could think of, but it seem...
When should I use an interface and when should I use a base class? Should it always be an interface if I don't want to actually define a base implementation of the methods? If I have a Dog and Cat ...
What are the differences in implementing interfaces implicitly and explicitly in C#? When should you use implicit and when should you use explicit? Are there any pros and/or cons to one or the other...
What exactly is the difference between an interface and abstract class?
(1) List<?> myList = new ArrayList<?>(); (2) ArrayList<?> myList = new ArrayList<?>(); I understand that with (1), implementations of the List interface can be swapped. It ...
How do I setup a class that represents an interface? Is this just an abstract base class?
How does one go about and try to find all subclasses of a given class (or all implementors of a given interface) in Java? As of now, I have a method to do this, but I find it quite inefficient (to say...
This may be a generic OOP question. I wanted to do a generic comparison between an interface and an abstract class on the basis of their usage. When would one want to use an interface and when would...
I am looking for a way to pass a method by reference. I understand that Java does not pass methods as parameters, however, I would like to get an alternative. I've been told interfaces are the alter...