Hi all, I have an interface question. I've been reading everywhere that you should use interfaces instead of abstract classes if at all possible. Now if I have a two functions that always does the same thing in five or six classes. One being something like getConnection() and the other something like buildXml(). Each of these functions do the exact same thing for all of the involved classes. Some are the same and some are not. Should I create an interface and then have to duplicate the code five or six times in each corresponding class? Or am I missing something basic on how to do this?
Spend like you don't need the money,
love like you've never been hurt and dance like no one's watching!
Spend like you don't need the money,
love like you've never been hurt and dance like no one's watching!