This page contains an archived post to the Java Answers Forum made prior to February 25, 2002.
If you wish to participate in discussions, please visit the new
Artima Forums.
Message:
Java
Posted by venu on December 13, 2000 at 8:18 AM
1 ans) If you examine carefully abstract classes provide the defintion or skelton part for members so that any one can implement and custonmize the methods as per the requirements. cheers venu > I wish to ask you certain doubts . While reading the subject , I got the feeling that most of the books are written with the 'how' and not 'why' approach . And certain design aspects are left unanswered . > Like : > 1) why was there a need for 'abstract classes' when ( seemingly) all the functionality could be achieved by the use of interface / concrete classes ? > 2) why didn't Sun provide for multiple inheritance for classes and did it for interfaces - as far as I could reckon , there is virtually no difference between the two ( an interface is as good as an abstract class ) ? ( I am not particularly convinced with the argument that it makes the compilers complex - after all it does exit already in C++ compiler .) > 3) how do togging interfaces viz. 'cloneable', ' serializable' etc. work ; which do not have any methods declared ( or defined ) inside them. Also, are these not the examples of multiple inheritance in some way ? > There must be more design aspects which I have not been able to come up to. I request you to please tell me where I can the answer to these questions as well as a more in depth dealing about why Java is the way it is . Please suggest me the readable books on the topic .
Replies:
- Re: A.P October 18, 2001 at 11:53 PM
(1)
- Java Design Matt Gerrans October 19, 2001 at 2:05 PM
(0)
|