View RSS Feed

My Java Tips

  1. Working With Interfaces

    by , 11-08-2011 at 07:33 PM (My Java Tips)
    Interface is very much similar to the Abstract class in Java but the difference is that in interfaces, members (methods) cannot be implemented, member(fields) defined will be treated as constants.
    A class becomes more formal about its behavior after implementing an interface. Interfaces are actually a contract between the class and the outside world. While implementing an interface in a concrete class, you have to implement all the methods defined by that interface. If you miss any method, ...
    Java SE